From fcfab2da194f0b468aad11c691fe6610e24e6060 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=BAben=20Carvalho?= Date: Tue, 14 Jan 2025 11:05:06 +0100 Subject: [PATCH] chore: remove exports.json files and hydrate exports script (#5020) --- package.json | 1 - packages/accordion/exports.json | 7 -- packages/action-bar/exports.json | 4 - packages/action-button/exports.json | 4 - packages/action-group/exports.json | 4 - packages/action-menu/exports.json | 5 - packages/alert-banner/exports.json | 4 - packages/alert-dialog/exports.json | 4 - packages/asset/exports.json | 4 - packages/avatar/exports.json | 4 - packages/badge/exports.json | 4 - packages/breadcrumbs/exports.json | 5 - packages/button-group/exports.json | 4 - packages/button/exports.json | 6 -- packages/card/exports.json | 4 - packages/checkbox/exports.json | 4 - packages/clear-button/exports.json | 4 - packages/close-button/exports.json | 4 - packages/coachmark/exports.json | 5 - packages/color-area/exports.json | 4 - packages/color-field/exports.json | 4 - packages/color-handle/exports.json | 4 - packages/color-loupe/exports.json | 4 - packages/color-slider/exports.json | 4 - packages/color-wheel/exports.json | 4 - packages/combobox/exports.json | 4 - packages/contextual-help/exports.json | 4 - packages/dialog/exports.json | 6 -- packages/divider/exports.json | 4 - packages/dropzone/exports.json | 4 - packages/field-group/exports.json | 4 - packages/field-label/exports.json | 4 - packages/help-text/exports.json | 6 -- packages/icon/exports.json | 4 - packages/icons/exports.json | 5 - packages/iconset/exports.json | 3 - packages/illustrated-message/exports.json | 4 - packages/infield-button/exports.json | 4 - packages/link/exports.json | 4 - packages/menu/exports.json | 7 -- packages/meter/exports.json | 4 - packages/modal/exports.json | 4 - packages/number-field/exports.json | 4 - packages/overlay/exports.json | 7 -- packages/picker-button/exports.json | 4 - packages/picker/exports.json | 5 - packages/popover/exports.json | 4 - packages/progress-bar/exports.json | 6 -- packages/progress-circle/exports.json | 4 - packages/radio/exports.json | 5 - packages/search/exports.json | 4 - packages/sidenav/exports.json | 6 -- packages/slider/exports.json | 6 -- packages/split-view/exports.json | 4 - packages/status-light/exports.json | 4 - packages/swatch/exports.json | 5 - packages/switch/exports.json | 4 - packages/table/exports.json | 11 -- packages/tabs/exports.json | 7 -- packages/tags/exports.json | 5 - packages/textfield/exports.json | 4 - packages/thumbnail/exports.json | 4 - packages/toast/exports.json | 4 - packages/tooltip/exports.json | 4 - packages/top-nav/exports.json | 5 - packages/tray/exports.json | 4 - packages/underlay/exports.json | 4 - projects/story-decorator/exports.json | 7 -- projects/vrt-compare/exports.json | 5 - tasks/hydrate-export-maps.js | 122 ---------------------- tasks/ts-tools.js | 12 +-- tools/base/exports.json | 9 -- tools/bundle/exports.json | 5 - tools/grid/exports.json | 5 - tools/opacity-checkerboard/exports.json | 4 - tools/reactive-controllers/exports.json | 3 - tools/shared/exports.json | 3 - tools/styles/exports.json | 63 ----------- tools/theme/exports.json | 21 ---- tools/truncated/exports.json | 5 - 80 files changed, 1 insertion(+), 567 deletions(-) delete mode 100644 packages/accordion/exports.json delete mode 100644 packages/action-bar/exports.json delete mode 100644 packages/action-button/exports.json delete mode 100644 packages/action-group/exports.json delete mode 100644 packages/action-menu/exports.json delete mode 100644 packages/alert-banner/exports.json delete mode 100644 packages/alert-dialog/exports.json delete mode 100644 packages/asset/exports.json delete mode 100644 packages/avatar/exports.json delete mode 100644 packages/badge/exports.json delete mode 100644 packages/breadcrumbs/exports.json delete mode 100644 packages/button-group/exports.json delete mode 100644 packages/button/exports.json delete mode 100644 packages/card/exports.json delete mode 100644 packages/checkbox/exports.json delete mode 100644 packages/clear-button/exports.json delete mode 100644 packages/close-button/exports.json delete mode 100644 packages/coachmark/exports.json delete mode 100644 packages/color-area/exports.json delete mode 100644 packages/color-field/exports.json delete mode 100644 packages/color-handle/exports.json delete mode 100644 packages/color-loupe/exports.json delete mode 100644 packages/color-slider/exports.json delete mode 100644 packages/color-wheel/exports.json delete mode 100644 packages/combobox/exports.json delete mode 100644 packages/contextual-help/exports.json delete mode 100644 packages/dialog/exports.json delete mode 100644 packages/divider/exports.json delete mode 100644 packages/dropzone/exports.json delete mode 100644 packages/field-group/exports.json delete mode 100644 packages/field-label/exports.json delete mode 100644 packages/help-text/exports.json delete mode 100644 packages/icon/exports.json delete mode 100644 packages/icons/exports.json delete mode 100644 packages/iconset/exports.json delete mode 100644 packages/illustrated-message/exports.json delete mode 100644 packages/infield-button/exports.json delete mode 100644 packages/link/exports.json delete mode 100644 packages/menu/exports.json delete mode 100644 packages/meter/exports.json delete mode 100644 packages/modal/exports.json delete mode 100644 packages/number-field/exports.json delete mode 100644 packages/overlay/exports.json delete mode 100644 packages/picker-button/exports.json delete mode 100644 packages/picker/exports.json delete mode 100644 packages/popover/exports.json delete mode 100644 packages/progress-bar/exports.json delete mode 100644 packages/progress-circle/exports.json delete mode 100644 packages/radio/exports.json delete mode 100644 packages/search/exports.json delete mode 100644 packages/sidenav/exports.json delete mode 100644 packages/slider/exports.json delete mode 100644 packages/split-view/exports.json delete mode 100644 packages/status-light/exports.json delete mode 100644 packages/swatch/exports.json delete mode 100644 packages/switch/exports.json delete mode 100644 packages/table/exports.json delete mode 100644 packages/tabs/exports.json delete mode 100644 packages/tags/exports.json delete mode 100644 packages/textfield/exports.json delete mode 100644 packages/thumbnail/exports.json delete mode 100644 packages/toast/exports.json delete mode 100644 packages/tooltip/exports.json delete mode 100644 packages/top-nav/exports.json delete mode 100644 packages/tray/exports.json delete mode 100644 packages/underlay/exports.json delete mode 100644 projects/story-decorator/exports.json delete mode 100644 projects/vrt-compare/exports.json delete mode 100644 tasks/hydrate-export-maps.js delete mode 100644 tools/base/exports.json delete mode 100644 tools/bundle/exports.json delete mode 100644 tools/grid/exports.json delete mode 100644 tools/opacity-checkerboard/exports.json delete mode 100644 tools/reactive-controllers/exports.json delete mode 100644 tools/shared/exports.json delete mode 100755 tools/styles/exports.json delete mode 100755 tools/theme/exports.json delete mode 100644 tools/truncated/exports.json diff --git a/package.json b/package.json index 67aa790871..94ec89cfe1 100755 --- a/package.json +++ b/package.json @@ -247,7 +247,6 @@ "!tools/**/*.d.ts", "tasks/esbuild-packages.js", "tasks/ts-tools.js", - "tasks/hydrate-export-maps.js", "packages/**/exports.json", "tools/**/exports.json" ], diff --git a/packages/accordion/exports.json b/packages/accordion/exports.json deleted file mode 100644 index 8927bcf28a..0000000000 --- a/packages/accordion/exports.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - ".": "./src/index.js", - "./src/*.js": "./src/*.js", - "./package.json": "./package.json", - "./sp-accordion.js": "./sp-accordion.js", - "./sp-accordion-item.js": "./sp-accordion-item.js" -} diff --git a/packages/action-bar/exports.json b/packages/action-bar/exports.json deleted file mode 100644 index a5542ca200..0000000000 --- a/packages/action-bar/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-action-bar.js": "./sp-action-bar.js" -} diff --git a/packages/action-button/exports.json b/packages/action-button/exports.json deleted file mode 100644 index cf0157ba10..0000000000 --- a/packages/action-button/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-action-button.js": "./sp-action-button.js" -} diff --git a/packages/action-group/exports.json b/packages/action-group/exports.json deleted file mode 100644 index ff5c6836a7..0000000000 --- a/packages/action-group/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-action-group.js": "./sp-action-group.js" -} diff --git a/packages/action-menu/exports.json b/packages/action-menu/exports.json deleted file mode 100644 index 7c2a3064d7..0000000000 --- a/packages/action-menu/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-action-menu.js": "./sp-action-menu.js", - "./sync/sp-action-menu.js": "./sync/sp-action-menu.js" -} diff --git a/packages/alert-banner/exports.json b/packages/alert-banner/exports.json deleted file mode 100644 index 0a1f1d452f..0000000000 --- a/packages/alert-banner/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./sp-alert-banner.js": "./sp-alert-banner.js" -} diff --git a/packages/alert-dialog/exports.json b/packages/alert-dialog/exports.json deleted file mode 100644 index 193b2ae591..0000000000 --- a/packages/alert-dialog/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-alert-dialog.js": "./sp-alert-dialog.js" -} diff --git a/packages/asset/exports.json b/packages/asset/exports.json deleted file mode 100644 index 61f35e073c..0000000000 --- a/packages/asset/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-asset.js": "./sp-asset.js" -} diff --git a/packages/avatar/exports.json b/packages/avatar/exports.json deleted file mode 100644 index fa078de12e..0000000000 --- a/packages/avatar/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-avatar.js": "./sp-avatar.js" -} diff --git a/packages/badge/exports.json b/packages/badge/exports.json deleted file mode 100644 index b426425cd4..0000000000 --- a/packages/badge/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-badge.js": "./sp-badge.js" -} diff --git a/packages/breadcrumbs/exports.json b/packages/breadcrumbs/exports.json deleted file mode 100644 index c7a686b80e..0000000000 --- a/packages/breadcrumbs/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./sp-breadcrumbs.js": "./sp-breadcrumbs.js", - "./sp-breadcrumb-item.js": "./sp-breadcrumb-item.js" -} diff --git a/packages/button-group/exports.json b/packages/button-group/exports.json deleted file mode 100644 index 4843c79fca..0000000000 --- a/packages/button-group/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-button-group.js": "./sp-button-group.js" -} diff --git a/packages/button/exports.json b/packages/button/exports.json deleted file mode 100644 index 8b80cc4965..0000000000 --- a/packages/button/exports.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-button.js": "./sp-button.js", - "./sp-clear-button.js": "./sp-clear-button.js", - "./sp-close-button.js": "./sp-close-button.js" -} diff --git a/packages/card/exports.json b/packages/card/exports.json deleted file mode 100644 index e4b80c0a4a..0000000000 --- a/packages/card/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-card.js": "./sp-card.js" -} diff --git a/packages/checkbox/exports.json b/packages/checkbox/exports.json deleted file mode 100644 index c550f9aa39..0000000000 --- a/packages/checkbox/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-checkbox.js": "./sp-checkbox.js" -} diff --git a/packages/clear-button/exports.json b/packages/clear-button/exports.json deleted file mode 100644 index df205c2ef7..0000000000 --- a/packages/clear-button/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - ".": "./src/clear-button.css.js", - "./src/*": "./src/*" -} diff --git a/packages/close-button/exports.json b/packages/close-button/exports.json deleted file mode 100644 index 77b6f5a212..0000000000 --- a/packages/close-button/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - ".": "./src/close-button.css.js", - "./src/*": "./src/*" -} diff --git a/packages/coachmark/exports.json b/packages/coachmark/exports.json deleted file mode 100644 index 6ac408d2dc..0000000000 --- a/packages/coachmark/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-coachmark.js": "./sp-coachmark.js", - "./sp-coach-indicator.js": "./sp-coach-indicator.js" -} diff --git a/packages/color-area/exports.json b/packages/color-area/exports.json deleted file mode 100644 index 122bc6e675..0000000000 --- a/packages/color-area/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-color-area.js": "./sp-color-area.js" -} diff --git a/packages/color-field/exports.json b/packages/color-field/exports.json deleted file mode 100644 index 8957d4a0a1..0000000000 --- a/packages/color-field/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-color-field.js": "./sp-color-field.js" -} diff --git a/packages/color-handle/exports.json b/packages/color-handle/exports.json deleted file mode 100644 index a23164d11b..0000000000 --- a/packages/color-handle/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-color-handle.js": "./sp-color-handle.js" -} diff --git a/packages/color-loupe/exports.json b/packages/color-loupe/exports.json deleted file mode 100644 index 6263255799..0000000000 --- a/packages/color-loupe/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-color-loupe.js": "./sp-color-loupe.js" -} diff --git a/packages/color-slider/exports.json b/packages/color-slider/exports.json deleted file mode 100644 index 2d857b6038..0000000000 --- a/packages/color-slider/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-color-slider.js": "./sp-color-slider.js" -} diff --git a/packages/color-wheel/exports.json b/packages/color-wheel/exports.json deleted file mode 100644 index 9bed880cf7..0000000000 --- a/packages/color-wheel/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-color-wheel.js": "./sp-color-wheel.js" -} diff --git a/packages/combobox/exports.json b/packages/combobox/exports.json deleted file mode 100644 index 5d4afca82a..0000000000 --- a/packages/combobox/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-combobox.js": "./sp-combobox.js" -} diff --git a/packages/contextual-help/exports.json b/packages/contextual-help/exports.json deleted file mode 100644 index 5a85666a1b..0000000000 --- a/packages/contextual-help/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./sp-contextual-help.js": "./sp-contextual-help.js" -} diff --git a/packages/dialog/exports.json b/packages/dialog/exports.json deleted file mode 100644 index 37ec99ec94..0000000000 --- a/packages/dialog/exports.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-dialog.js": "./sp-dialog.js", - "./sp-dialog-base.js": "./sp-dialog-base.js", - "./sp-dialog-wrapper.js": "./sp-dialog-wrapper.js" -} diff --git a/packages/divider/exports.json b/packages/divider/exports.json deleted file mode 100644 index 8d8460dc6c..0000000000 --- a/packages/divider/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-divider.js": "./sp-divider.js" -} diff --git a/packages/dropzone/exports.json b/packages/dropzone/exports.json deleted file mode 100644 index 3246cfff81..0000000000 --- a/packages/dropzone/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-dropzone.js": "./sp-dropzone.js" -} diff --git a/packages/field-group/exports.json b/packages/field-group/exports.json deleted file mode 100644 index f48acef66d..0000000000 --- a/packages/field-group/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-field-group.js": "./sp-field-group.js" -} diff --git a/packages/field-label/exports.json b/packages/field-label/exports.json deleted file mode 100644 index a86253ea8a..0000000000 --- a/packages/field-label/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-field-label.js": "./sp-field-label.js" -} diff --git a/packages/help-text/exports.json b/packages/help-text/exports.json deleted file mode 100644 index 486da8b3d9..0000000000 --- a/packages/help-text/exports.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "./src/*": "./src/*", - "./help-text-manager.js": "./src/help-text-manager.js", - "./HelpTextManager.js": "./src/HelpTextManager.js", - "./sp-help-text.js": "./sp-help-text.js" -} diff --git a/packages/icon/exports.json b/packages/icon/exports.json deleted file mode 100644 index d175c1bc59..0000000000 --- a/packages/icon/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-icon.js": "./sp-icon.js" -} diff --git a/packages/icons/exports.json b/packages/icons/exports.json deleted file mode 100644 index 5d5575f540..0000000000 --- a/packages/icons/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-icons-large.js": "./sp-icons-large.js", - "./sp-icons-medium.js": "./sp-icons-medium.js" -} diff --git a/packages/iconset/exports.json b/packages/iconset/exports.json deleted file mode 100644 index 266304b99d..0000000000 --- a/packages/iconset/exports.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "./src/*": "./src/*" -} diff --git a/packages/illustrated-message/exports.json b/packages/illustrated-message/exports.json deleted file mode 100644 index 3a5f0e66e9..0000000000 --- a/packages/illustrated-message/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-illustrated-message.js": "./sp-illustrated-message.js" -} diff --git a/packages/infield-button/exports.json b/packages/infield-button/exports.json deleted file mode 100644 index 32b3a5833e..0000000000 --- a/packages/infield-button/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./sp-infield-button.js": "./sp-infield-button.js" -} diff --git a/packages/link/exports.json b/packages/link/exports.json deleted file mode 100644 index 4a7dfdc792..0000000000 --- a/packages/link/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-link.js": "./sp-link.js" -} diff --git a/packages/menu/exports.json b/packages/menu/exports.json deleted file mode 100644 index ed22af3506..0000000000 --- a/packages/menu/exports.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-menu.js": "./sp-menu.js", - "./sp-menu-divider.js": "./sp-menu-divider.js", - "./sp-menu-group.js": "./sp-menu-group.js", - "./sp-menu-item.js": "./sp-menu-item.js" -} diff --git a/packages/meter/exports.json b/packages/meter/exports.json deleted file mode 100644 index 5cc9f63675..0000000000 --- a/packages/meter/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-meter.js": "./sp-meter.js" -} diff --git a/packages/modal/exports.json b/packages/modal/exports.json deleted file mode 100644 index 77a9c67346..0000000000 --- a/packages/modal/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - ".": "./src/modal-wrapper.css.js", - "./src/*": "./src/*" -} diff --git a/packages/number-field/exports.json b/packages/number-field/exports.json deleted file mode 100644 index 04a2d0987f..0000000000 --- a/packages/number-field/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./sp-number-field.js": "./sp-number-field.js" -} diff --git a/packages/overlay/exports.json b/packages/overlay/exports.json deleted file mode 100644 index 3fcf3c9b2b..0000000000 --- a/packages/overlay/exports.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "./src/*": "./src/*", - "./active-overlay.js": "./active-overlay.js", - "./overlay-trigger.js": "./overlay-trigger.js", - "./sync/overlay-trigger.js": "./sync/overlay-trigger.js", - "./sp-overlay.js": "./sp-overlay.js" -} diff --git a/packages/picker-button/exports.json b/packages/picker-button/exports.json deleted file mode 100644 index 4c49d29a90..0000000000 --- a/packages/picker-button/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-picker-button.js": "./sp-picker-button.js" -} diff --git a/packages/picker/exports.json b/packages/picker/exports.json deleted file mode 100644 index ebf5a31a4f..0000000000 --- a/packages/picker/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./sync/*": "./sync/*", - "./sp-picker.js": "./sp-picker.js" -} diff --git a/packages/popover/exports.json b/packages/popover/exports.json deleted file mode 100644 index 5aec5e57f6..0000000000 --- a/packages/popover/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-popover.js": "./sp-popover.js" -} diff --git a/packages/progress-bar/exports.json b/packages/progress-bar/exports.json deleted file mode 100644 index 6c79d2b38e..0000000000 --- a/packages/progress-bar/exports.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - ".": "./src/index.js", - "./src/*.js": "./src/*.js", - "./package.json": "./package.json", - "./sp-progress-bar.js": "./sp-progress-bar.js" -} diff --git a/packages/progress-circle/exports.json b/packages/progress-circle/exports.json deleted file mode 100644 index 30c15ad849..0000000000 --- a/packages/progress-circle/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-progress-circle.js": "./sp-progress-circle.js" -} diff --git a/packages/radio/exports.json b/packages/radio/exports.json deleted file mode 100644 index b4c63f03d8..0000000000 --- a/packages/radio/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-radio.js": "./sp-radio.js", - "./sp-radio-group.js": "./sp-radio-group.js" -} diff --git a/packages/search/exports.json b/packages/search/exports.json deleted file mode 100644 index 8db4a9af07..0000000000 --- a/packages/search/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-search.js": "./sp-search.js" -} diff --git a/packages/sidenav/exports.json b/packages/sidenav/exports.json deleted file mode 100644 index f418bd6a93..0000000000 --- a/packages/sidenav/exports.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-sidenav.js": "./sp-sidenav.js", - "./sp-sidenav-heading.js": "./sp-sidenav-heading.js", - "./sp-sidenav-item.js": "./sp-sidenav-item.js" -} diff --git a/packages/slider/exports.json b/packages/slider/exports.json deleted file mode 100644 index 79db2ab876..0000000000 --- a/packages/slider/exports.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-slider.js": "./sp-slider.js", - "./sp-slider-handle.js": "./sp-slider-handle.js", - "./sync/sp-slider.js": "./sync/sp-slider.js" -} diff --git a/packages/split-view/exports.json b/packages/split-view/exports.json deleted file mode 100644 index 2e2b381228..0000000000 --- a/packages/split-view/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-split-view.js": "./sp-split-view.js" -} diff --git a/packages/status-light/exports.json b/packages/status-light/exports.json deleted file mode 100644 index 961bf504e0..0000000000 --- a/packages/status-light/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-status-light.js": "./sp-status-light.js" -} diff --git a/packages/swatch/exports.json b/packages/swatch/exports.json deleted file mode 100644 index 79728fb4b2..0000000000 --- a/packages/swatch/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-swatch.js": "./sp-swatch.js", - "./sp-swatch-group.js": "./sp-swatch-group.js" -} diff --git a/packages/switch/exports.json b/packages/switch/exports.json deleted file mode 100644 index 0ad1e755de..0000000000 --- a/packages/switch/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-switch.js": "./sp-switch.js" -} diff --git a/packages/table/exports.json b/packages/table/exports.json deleted file mode 100644 index b6c55e0020..0000000000 --- a/packages/table/exports.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./elements.js": "./elements.js", - "./sp-table-body.js": "./sp-table-body.js", - "./sp-table-cell.js": "./sp-table-cell.js", - "./sp-table-checkbox-cell.js": "./sp-table-checkbox-cell.js", - "./sp-table-head.js": "./sp-table-head.js", - "./sp-table-head-cell.js": "./sp-table-head-cell.js", - "./sp-table-row.js": "./sp-table-row.js", - "./sp-table.js": "./sp-table.js" -} diff --git a/packages/tabs/exports.json b/packages/tabs/exports.json deleted file mode 100644 index b0e445e52e..0000000000 --- a/packages/tabs/exports.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-tabs.js": "./sp-tabs.js", - "./sp-tab.js": "./sp-tab.js", - "./sp-tab-panel.js": "./sp-tab-panel.js", - "./sp-tabs-overflow.js": "./sp-tabs-overflow.js" -} diff --git a/packages/tags/exports.json b/packages/tags/exports.json deleted file mode 100644 index 97d817cf96..0000000000 --- a/packages/tags/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-tags.js": "./sp-tags.js", - "./sp-tag.js": "./sp-tag.js" -} diff --git a/packages/textfield/exports.json b/packages/textfield/exports.json deleted file mode 100644 index e0552ac384..0000000000 --- a/packages/textfield/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-textfield.js": "./sp-textfield.js" -} diff --git a/packages/thumbnail/exports.json b/packages/thumbnail/exports.json deleted file mode 100644 index 07e36a4497..0000000000 --- a/packages/thumbnail/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-thumbnail.js": "./sp-thumbnail.js" -} diff --git a/packages/toast/exports.json b/packages/toast/exports.json deleted file mode 100644 index a68dedade4..0000000000 --- a/packages/toast/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-toast.js": "./sp-toast.js" -} diff --git a/packages/tooltip/exports.json b/packages/tooltip/exports.json deleted file mode 100644 index f302324068..0000000000 --- a/packages/tooltip/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-tooltip.js": "./sp-tooltip.js" -} diff --git a/packages/top-nav/exports.json b/packages/top-nav/exports.json deleted file mode 100644 index 304453b068..0000000000 --- a/packages/top-nav/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-top-nav.js": "./sp-top-nav.js", - "./sp-top-nav-item.js": "./sp-top-nav-item.js" -} diff --git a/packages/tray/exports.json b/packages/tray/exports.json deleted file mode 100644 index f83d973584..0000000000 --- a/packages/tray/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./sp-tray.js": "./sp-tray.js" -} diff --git a/packages/underlay/exports.json b/packages/underlay/exports.json deleted file mode 100644 index d08b4270fc..0000000000 --- a/packages/underlay/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "./src/*": "./src/*", - "./sp-underlay.js": "./sp-underlay.js" -} diff --git a/projects/story-decorator/exports.json b/projects/story-decorator/exports.json deleted file mode 100644 index efabe7da06..0000000000 --- a/projects/story-decorator/exports.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./decorator": "./decorator.js", - "./decorator.js": "./decorator.js", - "./sp-story-decorator": "./sp-story-decorator.js", - "./sp-story-decorator.js": "./sp-story-decorator.js" -} diff --git a/projects/vrt-compare/exports.json b/projects/vrt-compare/exports.json deleted file mode 100644 index b0c5adb895..0000000000 --- a/projects/vrt-compare/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./vrt-compare": "./vrt-compare.js", - "./vrt-compare.js": "./vrt-compare.js" -} diff --git a/tasks/hydrate-export-maps.js b/tasks/hydrate-export-maps.js deleted file mode 100644 index e44fd85315..0000000000 --- a/tasks/hydrate-export-maps.js +++ /dev/null @@ -1,122 +0,0 @@ -/* -Copyright 2022 Adobe. All rights reserved. -This file is licensed to you under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. You may obtain a copy -of the License at http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software distributed under -the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS -OF ANY KIND, either express or implied. See the License for the specific language -governing permissions and limitations under the License. -*/ - -import path from 'path'; -import fs from 'fs'; -import fg from 'fast-glob'; - -const excludes = [ - // internal config file - './src/spectrum-config.js', - './src/spectrum-config.v1.js', - // partial only asset the is used to build other exports - /spectrum-(?!(([i][c][o][n][-])|([t][w][o]))).+\.css/, - /\.css$/, - /\.ts$/, - /\.map/, - './src/spectrum-vars.json', -]; - -/** - * - * Convert `exports.json` files into `exports` listings in the relative `package.json` file. - * - * - only affects packages with `exports.json` files - * - sets the following by default - * { - * '.': { - * 'development': './src/index.dev.js', - * 'default': './src/index.js' - * }, - * './package.json': './package.json' - * } - * - explodes wildcards - * - excludes files in the `excludes` list above - * - does not expose `development` conditions on `*.css.js` files & version.js file - * - saves back into the `package.json` without linting - * - */ - -const hydrateExportMap = async (exportMapPath) => { - const exportMapSrc = JSON.parse(fs.readFileSync(exportMapPath, 'utf8')); - const exportMapResolved = {}; - const exportMapExploded = { - '.': { - development: './src/index.dev.js', - default: './src/index.js', - }, - './package.json': './package.json', - }; - for (const key in exportMapSrc) { - if (key.search(/\*/) > -1) { - // If there is a wildcard in the list, resolve it to all the requires exports. - // Get the depth between the script location and the package location so that number of - // directories can be removed from the path set to the map. - const depth = exportMapPath.split('/').length - 1; - const blob = path.join(exportMapPath, '..', key); - for (const fullExportPath of await fg(blob, { - ignore: ['**/*.dev.js'], - })) { - const exportPath = - './' + - fullExportPath.split(path.sep).splice(depth).join(path.sep); - if ( - excludes.some((exclude) => exportPath.search(exclude) > -1) - ) { - // skip excludes - continue; - } - exportMapResolved[exportPath] = exportPath; - } - } else { - exportMapResolved[key] = exportMapSrc[key]; - } - } - for (const key in exportMapResolved) { - if ( - key.endsWith('.css.js') || - exportMapResolved[key].endsWith('.css.js') || - (key !== '.' && !key.endsWith('.js')) || - (key.endsWith('version.js') && !key.endsWith('core-tokens.js')) - ) { - // simple map for assets without "development" versions - exportMapExploded[key] = exportMapResolved[key]; - continue; - } - // exploded map for assets with "development" versions - const exportPath = key === '.' ? exportMapResolved[key] : key; - exportMapExploded[key] = { - development: exportPath.replace('.js', '.dev.js'), - default: exportPath, - }; - } - const packageJSONPath = path.join(exportMapPath, '..', 'package.json'); - const packageJSON = JSON.parse(fs.readFileSync(packageJSONPath, 'utf8')); - packageJSON.exports = exportMapExploded; - fs.writeFileSync( - packageJSONPath, - JSON.stringify(packageJSON, null, ' ') + '\n', - { - encoding: 'utf8', - } - ); -}; - -const hydrateExportMaps = async () => { - for (const exportMap of await fg(`./**/exports.json`, { - ignore: ['**/node_modules/**'], - })) { - hydrateExportMap(exportMap); - } -}; - -hydrateExportMaps(); diff --git a/tasks/ts-tools.js b/tasks/ts-tools.js index 2849ccc08d..ebe5ffb510 100644 --- a/tasks/ts-tools.js +++ b/tasks/ts-tools.js @@ -13,7 +13,6 @@ governing permissions and limitations under the License. import fg from 'fast-glob'; import { build } from 'esbuild'; import fs from 'fs'; -import { execSync } from 'child_process'; const relativeImportRegex = RegExp( 'import([^;]+)["|\'](?![a-zA-Z@])(..+)(? { - execSync('node ./tasks/hydrate-export-maps.js'); - }); - }, -}; - export const buildPackage = async (paths) => { const devPaths = paths.filter( (path) => @@ -80,7 +70,7 @@ export const buildPackage = async (paths) => { (path) => path.search('/test/') > -1 || path.search('/stories/') > -1 ); const devPlugins = [makeDev]; - const prodPlugins = [makeExports]; + const prodPlugins = []; const builds = []; const config = { bundle: false, diff --git a/tools/base/exports.json b/tools/base/exports.json deleted file mode 100644 index a7d63910c8..0000000000 --- a/tools/base/exports.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "./src/*": "./src/*", - "./condition-attribute-with-id.js": "./src/condition-attribute-with-id.js", - "./decorators.js": "./src/decorators.js", - "./directives.js": "./src/directives.js", - "./directive.js": "./src/directive.js", - "./html.js": "./src/html.js", - "./streaming-listener.js": "./src/streaming-listener.js" -} diff --git a/tools/bundle/exports.json b/tools/bundle/exports.json deleted file mode 100644 index a9e8dfdcec..0000000000 --- a/tools/bundle/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*", - "./elements.js": "./elements.js", - "./icons.js": "./src/icons.js" -} diff --git a/tools/grid/exports.json b/tools/grid/exports.json deleted file mode 100644 index 119fc7a4f4..0000000000 --- a/tools/grid/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./sp-grid": "./sp-grid.js", - "./sp-grid.js": "./sp-grid.js" -} diff --git a/tools/opacity-checkerboard/exports.json b/tools/opacity-checkerboard/exports.json deleted file mode 100644 index b652713111..0000000000 --- a/tools/opacity-checkerboard/exports.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - ".": "./src/opacity-checkerboard.css.js", - "./src/*": "./src/*" -} diff --git a/tools/reactive-controllers/exports.json b/tools/reactive-controllers/exports.json deleted file mode 100644 index 266304b99d..0000000000 --- a/tools/reactive-controllers/exports.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "./src/*": "./src/*" -} diff --git a/tools/shared/exports.json b/tools/shared/exports.json deleted file mode 100644 index 266304b99d..0000000000 --- a/tools/shared/exports.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "./src/*": "./src/*" -} diff --git a/tools/styles/exports.json b/tools/styles/exports.json deleted file mode 100755 index 0de880ce69..0000000000 --- a/tools/styles/exports.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - ".": "./src/spectrum-base.css.js", - "./all-large-dark.css": "./all-large-dark.css", - "./all-large-darkest.css": "./all-large-darkest.css", - "./all-large-light.css": "./all-large-light.css", - "./all-large-lightest.css": "./all-large-lightest.css", - "./all-medium-dark.css": "./all-medium-dark.css", - "./all-medium-darkest.css": "./all-medium-darkest.css", - "./all-medium-light.css": "./all-medium-light.css", - "./all-medium-lightest.css": "./all-medium-lightest.css", - "./core-global.css": "./core-global.css", - "./express/core-global.css": "./express/core-global.css", - "./scale-large.css": "./scale-large.css", - "./express/scale-large.css": "./express/scale-large.css", - "./scale-medium.css": "./scale-medium.css", - "./express/scale-medium.css": "./express/scale-medium.css", - "./theme-dark.css": "./theme-dark.css", - "./express/theme-dark.css": "./express/theme-dark.css", - "./theme-darkest.css": "./theme-darkest.css", - "./express/theme-darkest.css": "./express/theme-darkest.css", - "./theme-light.css": "./theme-light.css", - "./express/theme-light.css": "./express/theme-light.css", - "./theme-lightest.css": "./theme-lightest.css", - "./express/theme-lightest.css": "./express/theme-lightest.css", - "./typography.css": "./typography.css", - "./body.js": "./body.js", - "./code.js": "./code.js", - "./detail.js": "./detail.js", - "./heading.js": "./heading.js", - "./typography.js": "./typography.js", - "./src/*": "./src/*", - "./tokens/*": "./tokens/*", - "./tokens-v2/*": "./tokens-v2/*", - "./src/spectrum-base.css": "./src/spectrum-base.css", - "./src/spectrum-body.css": "./src/spectrum-body.css", - "./src/body-overrides.css": "./src/body-overrides.css", - "./src/spectrum-code.css": "./src/spectrum-code.css", - "./src/code-overrides.css": "./src/code-overrides.css", - "./src/spectrum-detail.css": "./src/spectrum-code.css", - "./src/detail-overrides.css": "./src/detail-overrides.css", - "./src/spectrum-heading.css": "./src/spectrum-heading.css", - "./src/heading-overrides.css": "./src/heading-overrides.css", - "./src/spectrum-lang.css": "./src/spectrum-lang.css", - "./src/lang-overrides.css": "./src/lang-overrides.css", - "./src/spectrum-typography.css": "./src/spectrum-typography.css", - "./tokens/express/custom-large-vars.css": "./tokens/express/custom-large-vars.css", - "./tokens/express/custom-medium-vars.css": "./tokens/express/custom-medium-vars.css", - "./tokens/express/custom-vars.css": "./tokens/express/custom-vars.css", - "./tokens/express/global-vars.css": "./tokens/express/global-vars.css", - "./tokens/express/large-vars.css": "./tokens/express/large-vars.css", - "./tokens/express/medium-vars.css": "./tokens/express/medium-vars.css", - "./tokens/spectrum/custom-large-vars.css": "./tokens/spectrum/custom-large-vars.css", - "./tokens/spectrum/custom-medium-vars.css": "./tokens/spectrum/custom-medium-vars.css", - "./tokens/spectrum/custom-vars.css": "./tokens/spectrum/custom-vars.css", - "./tokens/spectrum/global-vars.css": "./tokens/spectrum/global-vars.css", - "./tokens/spectrum/large-vars.css": "./tokens/spectrum/large-vars.css", - "./tokens/spectrum/medium-vars.css": "./tokens/spectrum/medium-vars.css", - "./tokens-v2/spectrum/custom-large-vars.css": "./tokens-v2/spectrum/custom-large-vars.css", - "./tokens-v2/spectrum/custom-medium-vars.css": "./tokens-v2/spectrum/custom-medium-vars.css", - "./tokens-v2/spectrum/custom-vars.css": "./tokens-v2/spectrum/custom-vars.css", - "./tokens-v2/spectrum/custom-dark-vars.css": "./tokens-v2/spectrum/custom-dark-vars.css", - "./tokens-v2/spectrum/custom-light-vars.css": "./tokens-v2/spectrum/custom-light-vars.css" -} diff --git a/tools/theme/exports.json b/tools/theme/exports.json deleted file mode 100755 index e6f90d2a41..0000000000 --- a/tools/theme/exports.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "./src/*": "./src/*", - "./express/*": "./express/*", - "./spectrum-two/*": "./spectrum-two/*", - "./src/express/*": "./src/express/*", - "./src/spectrum-two/*": "./src/spectrum-two/*", - "./core.js": "./core.js", - "./sp-theme.js": "./sp-theme.js", - "./scale-medium.js": "./scale-medium.js", - "./scale-medium-core-tokens.js": "./scale-medium-core-tokens.js", - "./scale-large.js": "./scale-large.js", - "./scale-large-core-tokens.js": "./scale-large-core-tokens.js", - "./theme-lightest.js": "./theme-lightest.js", - "./theme-lightest-core-tokens.js": "./theme-lightest-core-tokens.js", - "./theme-light.js": "./theme-light.js", - "./theme-light-core-tokens.js": "./theme-light-core-tokens.js", - "./theme-dark.js": "./theme-dark.js", - "./theme-dark-core-tokens.js": "./theme-dark-core-tokens.js", - "./theme-darkest.js": "./theme-darkest.js", - "./theme-darkest-core-tokens.js": "./theme-darkest-core-tokens.js" -} diff --git a/tools/truncated/exports.json b/tools/truncated/exports.json deleted file mode 100644 index b0373584d0..0000000000 --- a/tools/truncated/exports.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "./src/*": "./src/*.js", - "./sp-truncated": "./sp-truncated.js", - "./sp-truncated.js": "./sp-truncated.js" -}