Add css-browser-selector as bazel rule, and update from 0.4.0 to 0.6.5
This commit is contained in:
parent
4da27afba8
commit
bfd9c93e61
|
@ -0,0 +1,29 @@
|
|||
load("//ts:copy.bzl", "copy_files")
|
||||
|
||||
"Rule to copy css-browser-selector subset from node_modules to vendor folder."
|
||||
|
||||
_include = [
|
||||
"css-browser-selector.min.js",
|
||||
]
|
||||
|
||||
_unwanted_prefix = "external/npm/node_modules/css-browser-selector/"
|
||||
|
||||
def _copy_browsersel(ctx):
|
||||
wanted = []
|
||||
for f in ctx.attr.browsersel.files.to_list():
|
||||
path = f.path
|
||||
want = True
|
||||
|
||||
for substr in _include:
|
||||
if substr in path:
|
||||
output = path.replace(_unwanted_prefix, "")
|
||||
wanted.append((f, output))
|
||||
|
||||
return copy_files(ctx, wanted)
|
||||
|
||||
copy_browsersel = rule(
|
||||
implementation = _copy_browsersel_impl,
|
||||
attrs = {
|
||||
"browsersel": attr.label(default = "@npm//css-browser-selector:css_browser-selector__files"),
|
||||
},
|
||||
)
|
|
@ -99,6 +99,13 @@
|
|||
"path": "node_modules/protobufjs/node_modules/@types/node",
|
||||
"licenseFile": "node_modules/protobufjs/node_modules/@types/node/LICENSE"
|
||||
},
|
||||
"css-browser-selector@0.6.5": {
|
||||
"licenses": "CC-BY-SA-2.5",
|
||||
"repository": "https://github.com/verbatim/css_browser_selector",
|
||||
"publisher": "Rafael Lima",
|
||||
"path": "node_modules/css-browser-selector",
|
||||
"licenseFile": "node_modules/css-browser-selector/README.mkdn"
|
||||
},
|
||||
"d3-array@2.9.1": {
|
||||
"licenses": "BSD-3-Clause",
|
||||
"repository": "https://github.com/d3/d3-array",
|
||||
|
|
|
@ -52,6 +52,7 @@
|
|||
},
|
||||
"dependencies": {
|
||||
"@fluent/bundle": "^0.15.1",
|
||||
"css-browser-selector": "^0.6.5",
|
||||
"d3-array": "^2.8.0",
|
||||
"d3-axis": "^1.0.12",
|
||||
"d3-interpolate": "^1.4.0",
|
||||
|
|
|
@ -756,6 +756,11 @@ cross-spawn@^7.0.1:
|
|||
shebang-command "^2.0.0"
|
||||
which "^2.0.1"
|
||||
|
||||
css-browser-selector@^0.6.5:
|
||||
version "0.6.5"
|
||||
resolved "https://registry.yarnpkg.com/css-browser-selector/-/css-browser-selector-0.6.5.tgz#d2b06c01ff7d7cb455e2006b6b6558d39372ca60"
|
||||
integrity sha1-0rBsAf99fLRV4gBra2VY05NyymA=
|
||||
|
||||
csstype@^3.0.2:
|
||||
version "3.0.5"
|
||||
resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.0.5.tgz#7fdec6a28a67ae18647c51668a9ff95bb2fa7bb8"
|
||||
|
|
Loading…
Reference in New Issue