Remove highlightjs-solidity package since it doesnt comply along with webpack@5

pull/3494/head
Victor Baranov 4 years ago
parent d6e1e31fa2
commit 84d7ff968e
  1. 2
      apps/block_scout_web/assets/js/view_specific/address_contract/code_highlighting.js
  2. 11
      apps/block_scout_web/assets/package-lock.json
  3. 3
      apps/block_scout_web/assets/package.json
  4. 2
      apps/block_scout_web/lib/block_scout_web/views/smart_contract_view.ex

@ -1,9 +1,7 @@
import $ from 'jquery' import $ from 'jquery'
import hljs from 'highlight.js' import hljs from 'highlight.js'
import hljsDefineSolidity from 'highlightjs-solidity'
// only activate highlighting on pages with this selector // only activate highlighting on pages with this selector
if ($('[data-activate-highlight]').length > 0) { if ($('[data-activate-highlight]').length > 0) {
hljsDefineSolidity(hljs)
hljs.initHighlightingOnLoad() hljs.initHighlightingOnLoad()
} }

@ -6357,14 +6357,9 @@
"dev": true "dev": true
}, },
"highlight.js": { "highlight.js": {
"version": "9.18.1", "version": "10.4.0",
"resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.18.1.tgz", "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-10.4.0.tgz",
"integrity": "sha512-OrVKYz70LHsnCgmbXctv/bfuvntIKDz177h0Co37DQ5jamGZLVmoCVMtjMtNZY3X9DrCcKfklHPNeA0uPZhSJg==" "integrity": "sha512-EfrUGcQ63oLJbj0J0RI9ebX6TAITbsDBLbsjr881L/X5fMO9+oadKzEF21C7R3ULKG6Gv3uoab2HiqVJa/4+oA=="
},
"highlightjs-solidity": {
"version": "1.0.14",
"resolved": "https://registry.npmjs.org/highlightjs-solidity/-/highlightjs-solidity-1.0.14.tgz",
"integrity": "sha512-NhU/f45QKrdJzX9+rw6AC9oUvBdl9QBzsVHya74yJ8FEl1BpZwkT+0u9u5qg3zta3Ofh4quVmr+aLR1Mrvzvcg=="
}, },
"hmac-drbg": { "hmac-drbg": {
"version": "1.0.1", "version": "1.0.1",

@ -29,8 +29,7 @@
"core-js": "^2.6.12", "core-js": "^2.6.12",
"crypto-browserify": "^3.12.0", "crypto-browserify": "^3.12.0",
"eth-net-props": "^1.0.33", "eth-net-props": "^1.0.33",
"highlight.js": "^9.16.2", "highlight.js": "^10.4.0",
"highlightjs-solidity": "^1.0.8",
"https-browserify": "^1.0.0", "https-browserify": "^1.0.0",
"humps": "^2.0.1", "humps": "^2.0.1",
"jquery": "^3.4.0", "jquery": "^3.4.0",

@ -46,7 +46,7 @@ defmodule BlockScoutWeb.SmartContractView do
|> Enum.join(", ") |> Enum.join(", ")
end end
def values(values, type) when is_list(values) when type == "tuple[]" do def values(values, type) when is_list(values) and type == "tuple[]" do
array_from_tuple = tupple_to_array(values) array_from_tuple = tupple_to_array(values)
array_from_tuple_final = array_from_tuple_final =

Loading…
Cancel
Save