Spaces:
Paused
Paused
Download node_modules/@plotly/mapbox-gl/src/style-spec/empty.js from Leon4gr45/UserSyncFrontend: direct link, hf CLI and curl.
- Browser
- Download file 686 Bytes
-
https://huggingface.co/spaces/Leon4gr45/UserSyncFrontend/resolve/main/node_modules/%40plotly/mapbox-gl/src/style-spec/empty.js
- Command line
-
hf download hf://spaces/Leon4gr45/UserSyncFrontend/node_modules/@plotly/mapbox-gl/src/style-spec/empty.js
-
curl -L -o empty.js https://huggingface.co/spaces/Leon4gr45/UserSyncFrontend/resolve/main/node_modules/%40plotly/mapbox-gl/src/style-spec/empty.js
686 Bytes
| import latest from './reference/latest'; | |
| export default function emptyStyle() { | |
| const style = {}; | |
| const version = latest['$version']; | |
| for (const styleKey in latest['$root']) { | |
| const spec = latest['$root'][styleKey]; | |
| if (spec.required) { | |
| let value = null; | |
| if (styleKey === 'version') { | |
| value = version; | |
| } else { | |
| if (spec.type === 'array') { | |
| value = []; | |
| } else { | |
| value = {}; | |
| } | |
| } | |
| if (value != null) { | |
| style[styleKey] = value; | |
| } | |
| } | |
| } | |
| return style; | |
| } | |