Skip to content

Commit

Permalink
Complete lib/index.ts exports
Browse files Browse the repository at this point in the history
  • Loading branch information
cdauth committed Nov 16, 2023
1 parent 5500153 commit 409eb86
Show file tree
Hide file tree
Showing 9 changed files with 109 additions and 53 deletions.
13 changes: 13 additions & 0 deletions frontend/src/lib/bootstrap.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// Bootstrap import, see https://getbootstrap.com/docs/5.3/customize/optimize/#lean-javascript
import 'bootstrap/js/dist/alert';
import 'bootstrap/js/dist/button';
import 'bootstrap/js/dist/carousel';
// import 'bootstrap/js/dist/collapse';
import 'bootstrap/js/dist/dropdown';
import 'bootstrap/js/dist/modal';
// import 'bootstrap/js/dist/offcanvas';
import 'bootstrap/js/dist/popover';
// import 'bootstrap/js/dist/scrollspy';
import 'bootstrap/js/dist/tab';
import 'bootstrap/js/dist/toast';
import 'bootstrap/js/dist/tooltip';
34 changes: 17 additions & 17 deletions frontend/src/lib/components/toolbox/toolbox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
import Sidebar from "../ui/sidebar.vue";
import Icon from "../ui/icon.vue";
import { ref } from "vue";
import AddDropdown from "./add-dropdown.vue";
import CollabMapsDropdown from "./collab-maps-dropdown.vue";
import HelpDropdown from "./help-dropdown.vue";
import MapStyleDropdown from "./map-style-dropdown.vue";
import ToolsDropdown from "./tools-dropdown.vue";
import ViewsDropdown from "./views-dropdown.vue";
import ToolboxAddDropdown from "./toolbox-add-dropdown.vue";
import ToolboxCollabMapsDropdown from "./toolbox-collab-maps-dropdown.vue";
import ToolboxHelpDropdown from "./toolbox-help-dropdown.vue";
import ToolboxMapStyleDropdown from "./toolbox-map-style-dropdown.vue";
import ToolboxToolsDropdown from "./toolbox-tools-dropdown.vue";
import ToolboxViewsDropdown from "./toolbox-views-dropdown.vue";
import { injectContextRequired, requireClientContext } from "../facil-map-context-provider/facil-map-context-provider.vue";
const context = injectContextRequired();
Expand All @@ -34,32 +34,32 @@

<Sidebar :id="`fm${context.id}-toolbox-sidebar`" v-model:visible="sidebarVisible">
<ul class="navbar-nav">
<CollabMapsDropdown
<ToolboxCollabMapsDropdown
v-if="props.interactive"
@hide-sidebar="sidebarVisible = false"
></CollabMapsDropdown>
></ToolboxCollabMapsDropdown>

<AddDropdown
<ToolboxAddDropdown
v-if="!client.readonly && client.padData"
@hide-sidebar="sidebarVisible = false"
></AddDropdown>
></ToolboxAddDropdown>

<ViewsDropdown
<ToolboxViewsDropdown
v-if="client.padData && (!client.readonly || Object.keys(client.views).length > 0)"
@hide-sidebar="sidebarVisible = false"
></ViewsDropdown>
></ToolboxViewsDropdown>

<MapStyleDropdown></MapStyleDropdown>
<ToolboxMapStyleDropdown></ToolboxMapStyleDropdown>

<ToolsDropdown
<ToolboxToolsDropdown
v-if="props.interactive || client.padData"
:interactive="props.interactive"
@hide-sidebar="sidebarVisible = false"
></ToolsDropdown>
></ToolboxToolsDropdown>

<HelpDropdown
<ToolboxHelpDropdown
@hide-sidebar="sidebarVisible = false"
></HelpDropdown>
></ToolboxHelpDropdown>
</ul>
</Sidebar>
</div>
Expand Down
115 changes: 79 additions & 36 deletions frontend/src/lib/index.ts
Original file line number Diff line number Diff line change
@@ -1,85 +1,128 @@
import "./styles.scss";

// Bootstrap import, see https://getbootstrap.com/docs/5.3/customize/optimize/#lean-javascript
import 'bootstrap/js/dist/alert';
import 'bootstrap/js/dist/button';
import 'bootstrap/js/dist/carousel';
// import 'bootstrap/js/dist/collapse';
import 'bootstrap/js/dist/dropdown';
import 'bootstrap/js/dist/modal';
// import 'bootstrap/js/dist/offcanvas';
import 'bootstrap/js/dist/popover';
// import 'bootstrap/js/dist/scrollspy';
import 'bootstrap/js/dist/tab';
import 'bootstrap/js/dist/toast';
import 'bootstrap/js/dist/tooltip';
import "./bootstrap.ts";

import { registerDeobfuscationHandlers } from "../utils/obfuscate";

registerDeobfuscationHandlers();

export * from "./utils/add";
export * from "./utils/bootstrap";
export { default as BoxSelection } from "./utils/box-selection";
export * from "./utils/box-selection";
export * from "./utils/carousel";
export * from "./utils/draw";
export * from "./utils/files";
export { default as FmHeightgraph } from "./utils/heightgraph";
export * from "./utils/heightgraph";
export { default as vLinkDisabled } from "./utils/link-disabled";
export * from "./utils/link-disabled";
export * from "./utils/modal";
export * from "./utils/search";
export { default as SelectionHandler } from "./utils/selection";
export * from "./utils/selection";
export { default as storage } from "./utils/storage";
export * from "./utils/storage";
export { default as vTooltip } from "./utils/tooltip";
export * from "./utils/tooltip";
export * from "./utils/ui";
export * from "./utils/utils";
export * from "./utils/vue";
export * from "./utils/zoom";

export * from "../utils/obfuscate";

export { default as AboutDialog } from "./components/about-dialog.vue";
export { default as ClickMarkerTab } from "./components/click-marker-tab.vue";
export { default as ClientContext } from "./components/client-provider.vue";
export { default as EditFilterDialog } from "./components/edit-filter-dialog.vue";
export { default as EditLineDialog } from "./components/edit-line-dialog.vue";
export { default as EditMarkerDialog } from "./components/edit-marker-dialog.vue";
export { default as EditTypeDialog } from "./components/edit-type-dialog/edit-type-dialog.vue";
export * from "./components/facil-map.vue";
export { default as FacilMap } from "./components/facil-map.vue";
export { default as FileResults } from "./components/file-results.vue";
export { default as EditTypeDropdownDialog } from "./components/edit-type-dialog/edit-type-dropdown-dialog.vue";
export * from "./components/edit-type-dialog/edit-type-utils";
export * from "./components/facil-map-context-provider/click-marker-tab-context";
export * from "./components/facil-map-context-provider/client-context";
export { default as FacilMapContextProvider } from "./components/facil-map-context-provider/facil-map-context-provider.vue";
export * from "./components/facil-map-context-provider/facil-map-context";
export * from "./components/facil-map-context-provider/import-tab-context";
export * from "./components/facil-map-context-provider/map-context";
export * from "./components/facil-map-context-provider/route-form-tab-context";
export * from "./components/facil-map-context-provider/search-box-context";
export * from "./components/facil-map-context-provider/search-form-tab-context";
export { default as HistoryDialog } from "./components/history-dialog/history-dialog.vue";
export { default as ImportTab } from "./components/import-tab.vue";
export * from "./components/leaflet-map/leaflet-map.vue";
export * from "./components/history-dialog/history-utils";
export * from "./components/leaflet-map/leaflet-map-components";
export { default as LeafletMap } from "./components/leaflet-map/leaflet-map.vue";
export { default as LegendContent } from "./components/legend/legend-content.vue";
export * from "./components/legend/legend-utils";
export { default as Legend } from "./components/legend/legend.vue";
export { default as LineInfoTab } from "./components/line-info/line-info-tab.vue";
export { default as LineInfo } from "./components/line-info/line-info.vue";
export { default as ManageBookmarksDialog } from "./components/manage-bookmarks-dialog.vue";
export { default as ManageTypesDialog } from "./components/manage-types-dialog.vue";
export { default as ManageViewsDialog } from "./components/manage-views-dialog.vue";
export { default as MarkerInfoTab } from "./components/marker-info/marker-info-tab.vue";
export { default as MarkerInfo } from "./components/marker-info/marker-info.vue";
export { default as MultipleInfoTab } from "./components/multiple-info/multiple-info-tab.vue";
export { default as MultipleInfo } from "./components/multiple-info/multiple-info.vue";
export { default as OpenMapDialog } from "./components/open-map-dialog.vue";
export { default as OverpassFormTab } from "./components/overpass-form/overpass-form-tab.vue";
export { default as OverpassForm } from "./components/overpass-form/overpass-form.vue";
export { default as PadIdEdit } from "./components/pad-settings-dialog/pad-settings-dialog.vue";
export { default as PadSettingsDialog } from "./components/pad-settings-dialog/pad-settings-dialog.vue";
export { default as RouteFormTab } from "./components/route-form/route-form-tab.vue";
export { default as RouteForm } from "./components/route-form/route-form.vue";
export { default as SaveViewDialog } from "./components/save-view-dialog.vue";
export * from "./components/search-box/search-box.vue";
export { default as SearchBoxTab } from "./components/search-box/search-box-tab.vue";
export { default as SearchBox } from "./components/search-box/search-box.vue";
export { default as SearchFormTab } from "./components/search-form/search-form-tab.vue";
export { default as SearchForm } from "./components/search-form/search-form.vue";
export { default as SearchResultInfo } from "./components/search-result-info.vue";
export { default as CustomImportDialog } from "./components/search-results/custom-import-dialog.vue";
export { default as SearchResults } from "./components/search-results/search-results.vue";
export { default as ToolboxAddDropdown } from "./components/toolbox/toolbox-add-dropdown.vue";
export { default as ToolboxCollabMapsDropdown } from "./components/toolbox/toolbox-collab-maps-dropdown.vue";
export { default as ToolboxHelpDropdown } from "./components/toolbox/toolbox-help-dropdown.vue";
export { default as ToolboxMapStyleDropdown } from "./components/toolbox/toolbox-map-style-dropdown.vue";
export { default as ToolboxToolsDropdown } from "./components/toolbox/toolbox-tools-dropdown.vue";
export { default as ToolboxViewsDropdown } from "./components/toolbox/toolbox-views-dropdown.vue";
export { default as Toolbox } from "./components/toolbox/toolbox.vue";

export { default as Toast } from "./components/ui/toasts/toast.vue";
export * from "./components/ui/toasts/toasts.vue";
export { default as Toasts } from "./components/ui/toasts/toasts.vue";
export * from "./components/ui/validated-form/validated-field.vue";
export { default as ValidatedField } from "./components/ui/validated-form/validated-field.vue";
export * from "./components/ui/validated-form/validated-form.vue";
export { default as ValidatedForm } from "./components/ui/validated-form/validated-form.vue";
export { default as AddToMapDropdown } from "./components/ui/add-to-map-dropdown.vue";
export * from "./components/ui/alert.vue";
export { default as Alert } from "./components/ui/alert.vue";
export { default as AttributePreservingElement } from "./components/ui/attribute-preserving-element.vue";
export { default as ColourPicker } from "./components/ui/colour-picker.vue";
export { default as Coordinates } from "./components/ui/coordinates.vue";
export { default as DropdownMenu } from "./components/ui/dropdown-menu.vue";
export { default as ElevationPlot } from "./components/ui/elevation-plot.vue";
export { default as ElevationStats } from "./components/ui/elevation-stats.vue";
export { default as ExportDropdown } from "./components/ui/export-dropdown.vue";
export { default as FieldInput } from "./components/ui/field-input.vue";
export { default as ModalDialog } from "./components/ui/modal-dialog.vue";
export { default as HybridPopover } from "./components/ui/hybrid-popover.vue";
export { default as Icon } from "./components/ui/icon.vue";
export { default as ModalDialog } from "./components/ui/modal-dialog.vue";
export { default as Picker } from "./components/ui/picker.vue";
export { default as Popover } from "./components/ui/popover.vue";
export { default as PrerenderedList } from "./components/ui/prerendered-list.vue";
export { default as RouteMode } from "./components/ui/route-mode.vue";
export { default as ShapePicker } from "./components/ui/shape-picker.vue";
export { default as Sidebar } from "./components/ui/sidebar.vue";
export { default as SizePicker } from "./components/ui/size-picker.vue";
export { default as SymbolPicker } from "./components/ui/symbol-picker.vue";
export { default as Toast } from "./components/ui/toasts/toast.vue";
export * from "./components/ui/toasts/toasts.vue";
export { default as WidthPicker } from "./components/ui/width-picker.vue";
export { default as UseAsDropdown } from "./components/ui/use-as-dropdown.vue";
export { default as WidthPicker } from "./components/ui/width-picker.vue";
export { default as ZoomToObjectButton } from "./components/ui/zoom-to-object-button.vue";

export { default as AboutDialog } from "./components/about-dialog.vue";
export { default as ClickMarkerTab } from "./components/click-marker-tab.vue";
export { default as ClientContext } from "./components/client-provider.vue";
export { default as EditFilterDialog } from "./components/edit-filter-dialog.vue";
export { default as EditLineDialog } from "./components/edit-line-dialog.vue";
export { default as EditMarkerDialog } from "./components/edit-marker-dialog.vue";
export * from "./components/facil-map.vue";
export { default as FacilMap } from "./components/facil-map.vue";
export { default as FileResults } from "./components/file-results.vue";
export { default as ImportTab } from "./components/import-tab.vue";
export { default as ManageBookmarksDialog } from "./components/manage-bookmarks-dialog.vue";
export { default as ManageTypesDialog } from "./components/manage-types-dialog.vue";
export { default as ManageViewsDialog } from "./components/manage-views-dialog.vue";
export { default as OpenMapDialog } from "./components/open-map-dialog.vue";
export { default as SaveViewDialog } from "./components/save-view-dialog.vue";
export { default as SearchResultInfo } from "./components/search-result-info.vue";
export { default as ShareDialog } from "./components/share-dialog.vue";

0 comments on commit 409eb86

Please sign in to comment.