@terraware/web-components 4.2.12 → 4.2.14-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/AntSwitch/index.js +8 -14
- package/components/Autocomplete/Autocomplete.js +67 -70
- package/components/Badge/index.js +16 -20
- package/components/BusySpinner/index.js +30 -35
- package/components/Button/Button.js +23 -27
- package/components/Button/button.test.js +8 -10
- package/components/Checkbox.js +10 -19
- package/components/Confirm/index.js +44 -51
- package/components/DatePicker/DatePicker.js +116 -117
- package/components/DialogBox/DialogBox.js +76 -66
- package/components/Divisor.js +15 -20
- package/components/Dropdown.js +54 -61
- package/components/EditableTable/index.js +129 -135
- package/components/ErrorBox/ErrorBox.js +37 -36
- package/components/FileChooser/index.js +73 -77
- package/components/FormBottomBar/index.js +63 -69
- package/components/Icon/Icon.js +14 -21
- package/components/Icon/icons/index.d.ts +1 -1
- package/components/Icon/icons/index.d.ts.map +1 -1
- package/components/Icon/icons/index.js +251 -255
- package/components/IconTooltip/index.js +29 -34
- package/components/Map/MapBox.js +199 -220
- package/components/Map/MapContainer.js +14 -18
- package/components/Map/MapDateSliderControl.js +44 -46
- package/components/Map/MapDrawer.js +32 -33
- package/components/Map/MapLegend.js +96 -95
- package/components/Map/MapViewStyleControl.js +38 -48
- package/components/Map/ReactMapboxWrapper.js +2 -9
- package/components/Map/index.js +47 -55
- package/components/Map/types.js +2 -8
- package/components/Map/useMaintainLayerOrder.js +4 -11
- package/components/Markdown/index.js +14 -21
- package/components/Message/Message.js +59 -51
- package/components/MultiSelect/MultiSelect.test.js +22 -24
- package/components/MultiSelect/index.js +73 -69
- package/components/Navbar/NavFooter.js +8 -13
- package/components/Navbar/NavItem.js +43 -37
- package/components/Navbar/NavSection.js +13 -17
- package/components/Navbar/Navbar.js +35 -38
- package/components/Navbar/SubNavbar.js +8 -13
- package/components/Note.js +14 -19
- package/components/OverlayModal/OverlayModal.js +36 -37
- package/components/PageForm/index.js +30 -35
- package/components/PhotoChooser/index.js +93 -98
- package/components/Pill/index.js +29 -31
- package/components/PillList/index.js +16 -22
- package/components/PlacementWrapper/index.js +20 -25
- package/components/PopoverMenu/Popover.js +33 -37
- package/components/PopoverMenu/index.js +41 -46
- package/components/PopoverMultiSelect/index.js +18 -21
- package/components/ProgressCircle/ProgressCircle.js +23 -26
- package/components/RadioButton.js +7 -14
- package/components/Select/Select.js +8 -13
- package/components/Select/SelectT.js +110 -108
- package/components/Separator/index.js +8 -14
- package/components/Size.js +1 -5
- package/components/Slider/index.js +7 -13
- package/components/SummaryBox.js +36 -39
- package/components/Tabs/index.js +75 -77
- package/components/TextTruncated/index.js +64 -65
- package/components/Textfield/Textfield.js +100 -95
- package/components/Textfield/TruncatedTextArea.js +44 -46
- package/components/TimelineSlider/TimelineMarker.js +24 -28
- package/components/TimelineSlider/TimelineRail.js +5 -11
- package/components/TimelineSlider/index.js +47 -51
- package/components/Tooltip/Tooltip.js +21 -26
- package/components/ViewPhotosDialog/index.js +58 -62
- package/components/VirtualWalkthrough/Annotation.d.ts +41 -0
- package/components/VirtualWalkthrough/Annotation.d.ts.map +1 -0
- package/components/VirtualWalkthrough/Annotation.js +197 -0
- package/components/VirtualWalkthrough/AnnotationEditPane.d.ts +20 -0
- package/components/VirtualWalkthrough/AnnotationEditPane.d.ts.map +1 -0
- package/components/VirtualWalkthrough/AnnotationEditPane.js +136 -0
- package/components/VirtualWalkthrough/AnnotationPanel.d.ts +13 -0
- package/components/VirtualWalkthrough/AnnotationPanel.d.ts.map +1 -0
- package/components/VirtualWalkthrough/AnnotationPanel.js +196 -0
- package/components/VirtualWalkthrough/Application.d.ts +9 -0
- package/components/VirtualWalkthrough/Application.d.ts.map +1 -0
- package/components/VirtualWalkthrough/Application.js +32 -0
- package/components/VirtualWalkthrough/AutoRotator.d.ts +109 -0
- package/components/VirtualWalkthrough/AutoRotator.d.ts.map +1 -0
- package/components/VirtualWalkthrough/AutoRotator.js +217 -0
- package/components/VirtualWalkthrough/BlockingSpinner.d.ts +3 -0
- package/components/VirtualWalkthrough/BlockingSpinner.d.ts.map +1 -0
- package/components/VirtualWalkthrough/BlockingSpinner.js +27 -0
- package/components/VirtualWalkthrough/BoundaryRing.d.ts +9 -0
- package/components/VirtualWalkthrough/BoundaryRing.d.ts.map +1 -0
- package/components/VirtualWalkthrough/BoundaryRing.js +33 -0
- package/components/VirtualWalkthrough/CameraInfo.d.ts +16 -0
- package/components/VirtualWalkthrough/CameraInfo.d.ts.map +1 -0
- package/components/VirtualWalkthrough/CameraInfo.js +88 -0
- package/components/VirtualWalkthrough/ControlsInfoPane.d.ts +37 -0
- package/components/VirtualWalkthrough/ControlsInfoPane.d.ts.map +1 -0
- package/components/VirtualWalkthrough/ControlsInfoPane.js +196 -0
- package/components/VirtualWalkthrough/GradientSky.d.ts +9 -0
- package/components/VirtualWalkthrough/GradientSky.d.ts.map +1 -0
- package/components/VirtualWalkthrough/GradientSky.js +73 -0
- package/components/VirtualWalkthrough/SplatControls.d.ts +50 -0
- package/components/VirtualWalkthrough/SplatControls.d.ts.map +1 -0
- package/components/VirtualWalkthrough/SplatControls.js +252 -0
- package/components/VirtualWalkthrough/SplatCrop.d.ts +8 -0
- package/components/VirtualWalkthrough/SplatCrop.d.ts.map +1 -0
- package/components/VirtualWalkthrough/SplatCrop.js +18 -0
- package/components/VirtualWalkthrough/SplatFadeCrop.d.ts +8 -0
- package/components/VirtualWalkthrough/SplatFadeCrop.d.ts.map +1 -0
- package/components/VirtualWalkthrough/SplatFadeCrop.js +18 -0
- package/components/VirtualWalkthrough/SplatModel.d.ts +15 -0
- package/components/VirtualWalkthrough/SplatModel.d.ts.map +1 -0
- package/components/VirtualWalkthrough/SplatModel.js +60 -0
- package/components/VirtualWalkthrough/SplatRevealRain.d.ts +18 -0
- package/components/VirtualWalkthrough/SplatRevealRain.d.ts.map +1 -0
- package/components/VirtualWalkthrough/SplatRevealRain.js +38 -0
- package/components/VirtualWalkthrough/TfAnnotationManager.d.ts +110 -0
- package/components/VirtualWalkthrough/TfAnnotationManager.d.ts.map +1 -0
- package/components/VirtualWalkthrough/TfAnnotationManager.js +368 -0
- package/components/VirtualWalkthrough/TfXrNavigation.d.ts +15 -0
- package/components/VirtualWalkthrough/TfXrNavigation.d.ts.map +1 -0
- package/components/VirtualWalkthrough/TfXrNavigation.js +24 -0
- package/components/VirtualWalkthrough/annotation-styles.css +5 -0
- package/components/VirtualWalkthrough/application-styles.css +4 -0
- package/components/VirtualWalkthrough/boundary-ring.d.ts +47 -0
- package/components/VirtualWalkthrough/boundary-ring.d.ts.map +1 -0
- package/components/VirtualWalkthrough/boundary-ring.js +125 -0
- package/components/VirtualWalkthrough/boundary-ring.test.js +109 -0
- package/components/VirtualWalkthrough/groundPlane.d.ts +14 -0
- package/components/VirtualWalkthrough/groundPlane.d.ts.map +1 -0
- package/components/VirtualWalkthrough/groundPlane.js +47 -0
- package/components/VirtualWalkthrough/groundPlane.test.js +45 -0
- package/components/VirtualWalkthrough/gsplat-fade-crop-effect.d.ts +19 -0
- package/components/VirtualWalkthrough/gsplat-fade-crop-effect.d.ts.map +1 -0
- package/components/VirtualWalkthrough/gsplat-fade-crop-effect.js +119 -0
- package/components/VirtualWalkthrough/walkthrough-camera.d.ts +77 -0
- package/components/VirtualWalkthrough/walkthrough-camera.d.ts.map +1 -0
- package/components/VirtualWalkthrough/walkthrough-camera.js +320 -0
- package/components/svg/BlobbyGrayIconImage.js +36 -41
- package/components/svg/BlobbyGrayIconImport.js +36 -41
- package/components/svg/BlobbyGrayIconUploadToTheCloud.js +36 -41
- package/components/svg/BlobbyIconCloudChecked.js +161 -158
- package/components/svg/BlobbyIconExportOrUploadPhoto.js +161 -158
- package/components/svg/BlobbyIconFolder.js +161 -158
- package/components/svg/BlobbyIconGraphReport.js +161 -158
- package/components/svg/BlobbyIconHappy.js +161 -158
- package/components/svg/BlobbyIconHeartMonitor.js +161 -158
- package/components/svg/BlobbyIconLeaf.js +161 -158
- package/components/svg/BlobbyIconLibrary.js +161 -158
- package/components/svg/BlobbyIconNursery.js +163 -160
- package/components/svg/BlobbyIconOrganization.js +161 -158
- package/components/svg/BlobbyIconParchment.js +161 -158
- package/components/svg/BlobbyIconPeople.js +161 -158
- package/components/svg/BlobbyIconSeedBank.js +161 -158
- package/components/svg/BlobbyIconSeedling.js +161 -158
- package/components/svg/BlobbyIconSeeds.js +161 -158
- package/components/svg/BlobbyIconSite.js +164 -161
- package/components/svg/BlobbyIconSparkles.js +161 -158
- package/components/svg/BlobbyIconWrench.js +161 -158
- package/components/svg/Bug.js +18 -27
- package/components/svg/Calendar.js +18 -27
- package/components/svg/CaretDown.js +18 -27
- package/components/svg/CaretLeft.js +18 -27
- package/components/svg/CaretRight.js +18 -27
- package/components/svg/CaretUp.js +18 -27
- package/components/svg/ChevronDown.js +18 -27
- package/components/svg/ChevronUp.js +18 -27
- package/components/svg/Close.js +18 -27
- package/components/svg/Critical.js +18 -27
- package/components/svg/Edit.js +161 -158
- package/components/svg/Error.js +18 -27
- package/components/svg/Filter.js +18 -27
- package/components/svg/Folder.js +18 -27
- package/components/svg/Help.js +18 -27
- package/components/svg/Home.js +18 -27
- package/components/svg/IconAdd.js +18 -27
- package/components/svg/IconArrowRight.js +19 -28
- package/components/svg/IconBusinessNetwork.js +18 -27
- package/components/svg/IconCalendar.d.ts +1 -1
- package/components/svg/IconCalendar.d.ts.map +1 -1
- package/components/svg/IconCalendar.js +18 -27
- package/components/svg/IconCancel.js +18 -27
- package/components/svg/IconChargingBattery.js +18 -27
- package/components/svg/IconChecklist.js +19 -28
- package/components/svg/IconCheckmark.js +18 -27
- package/components/svg/IconCoinInHand.js +18 -27
- package/components/svg/IconColumns.js +18 -27
- package/components/svg/IconComment.js +18 -27
- package/components/svg/IconDashboard.js +18 -27
- package/components/svg/IconDataMigration.js +18 -27
- package/components/svg/IconDocument.d.ts +8 -0
- package/components/svg/IconDocument.d.ts.map +1 -0
- package/components/svg/IconDocument.js +21 -0
- package/components/svg/IconDownloadFromTheCloud.js +19 -28
- package/components/svg/IconEdit.js +19 -28
- package/components/svg/IconExpand.js +19 -28
- package/components/svg/IconExport.js +18 -27
- package/components/svg/IconExternalLink.js +18 -27
- package/components/svg/IconEye.js +18 -27
- package/components/svg/IconEyeOff.js +18 -27
- package/components/svg/IconFile.js +18 -27
- package/components/svg/IconFolder.js +18 -27
- package/components/svg/IconFullScreen.js +18 -27
- package/components/svg/IconFutures.js +18 -27
- package/components/svg/IconGraphReport.js +18 -27
- package/components/svg/IconHeartMonitor.js +18 -27
- package/components/svg/IconHelp.js +19 -28
- package/components/svg/IconHistory.js +18 -27
- package/components/svg/IconImport.js +18 -27
- package/components/svg/IconIndex.js +18 -27
- package/components/svg/IconLayers.js +18 -27
- package/components/svg/IconLibrary.js +18 -27
- package/components/svg/IconList.js +18 -27
- package/components/svg/IconLivePlant.js +18 -27
- package/components/svg/IconLocations.js +18 -27
- package/components/svg/IconMail.js +18 -27
- package/components/svg/IconManager.js +18 -27
- package/components/svg/IconMarker.js +18 -27
- package/components/svg/IconMenu.js +18 -27
- package/components/svg/IconMenuHorizontal.js +18 -27
- package/components/svg/IconModule.js +18 -27
- package/components/svg/IconMyLocation.js +18 -27
- package/components/svg/IconNote.js +19 -28
- package/components/svg/IconNursery.js +18 -27
- package/components/svg/IconOrg.js +18 -27
- package/components/svg/IconParchment.js +18 -27
- package/components/svg/IconPhoto.js +18 -27
- package/components/svg/IconPlantsFilled.js +18 -27
- package/components/svg/IconRedo.js +18 -27
- package/components/svg/IconRestorationSite.js +18 -27
- package/components/svg/IconSeedBank.js +18 -27
- package/components/svg/IconSeedling.js +18 -27
- package/components/svg/IconSettings.js +18 -27
- package/components/svg/IconSlice.js +18 -27
- package/components/svg/IconSubmit.js +18 -27
- package/components/svg/IconSubtract.js +19 -28
- package/components/svg/IconSynced.js +18 -27
- package/components/svg/IconTrashCan.js +18 -27
- package/components/svg/IconTreasureMap.js +18 -27
- package/components/svg/IconUnavailable.js +18 -27
- package/components/svg/IconUndo.js +18 -27
- package/components/svg/IconVariable.js +18 -27
- package/components/svg/IconVideo.js +19 -28
- package/components/svg/IconWifi.js +18 -27
- package/components/svg/Info.js +18 -27
- package/components/svg/Key.js +18 -27
- package/components/svg/Leaf.js +18 -27
- package/components/svg/Lock.js +18 -27
- package/components/svg/Logo.js +40 -45
- package/components/svg/MenuVertical.js +18 -27
- package/components/svg/Notification.js +18 -27
- package/components/svg/Person.js +18 -27
- package/components/svg/Plus.js +18 -27
- package/components/svg/RestorationSite.js +18 -27
- package/components/svg/Search.js +18 -27
- package/components/svg/Seeds.js +18 -27
- package/components/svg/Site.js +18 -27
- package/components/svg/Sparkles.js +18 -27
- package/components/svg/Species.js +18 -27
- package/components/svg/Species2.js +161 -158
- package/components/svg/Spinner.js +27 -36
- package/components/svg/Star.js +18 -27
- package/components/svg/Success.js +18 -27
- package/components/svg/SuccessFilled.js +18 -27
- package/components/svg/TerrawareLogoDesktop.js +44 -49
- package/components/svg/TerrawareLogoMobile.js +20 -29
- package/components/svg/Touchscreen.js +18 -27
- package/components/svg/UploadCloud.js +161 -158
- package/components/svg/Warning.js +18 -27
- package/components/svg/WelcomeClipboard.js +130 -135
- package/components/svg/index.d.ts +1 -0
- package/components/svg/index.d.ts.map +1 -1
- package/components/svg/index.js +127 -888
- package/components/table/EnhancedTableToolbar.js +45 -47
- package/components/table/EnhancedTableToolbarV2.js +18 -26
- package/components/table/TableCellRenderer.js +137 -143
- package/components/table/TableHeader.js +45 -47
- package/components/table/TableHeaderItem.js +65 -64
- package/components/table/density.js +3 -11
- package/components/table/index.js +225 -218
- package/components/table/sort.js +8 -18
- package/components/table/sort.test.js +6 -8
- package/components/table/types.js +1 -5
- package/components/types/index.js +1 -5
- package/hooks/useBoolean.d.ts +4 -0
- package/hooks/useBoolean.d.ts.map +1 -0
- package/hooks/useBoolean.js +12 -0
- package/hooks/useCameraPosition.d.ts +8 -0
- package/hooks/useCameraPosition.d.ts.map +1 -0
- package/hooks/useCameraPosition.js +33 -0
- package/index.js +57 -398
- package/license-report.html +1 -1
- package/package.json +10 -3
- package/style-dictionary-dist/TerrawareTheme.js +1 -7
- package/theme.js +7 -14
- package/utils/color.d.ts +2 -0
- package/utils/color.d.ts.map +1 -0
- package/utils/color.js +14 -0
- package/utils/date.js +13 -24
- package/utils/date.test.js +40 -43
- package/utils/index.js +5 -53
- package/utils/preventDefaultEvent.js +1 -7
- package/utils/text.js +2 -9
- package/utils/text.test.js +9 -11
- package/utils/useDeviceInfo.js +10 -16
- package/virtualWalkthrough.d.ts +31 -0
- package/virtualWalkthrough.d.ts.map +1 -0
- package/virtualWalkthrough.js +28 -0
package/theme.js
CHANGED
|
@@ -1,13 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
-
Object.defineProperty(exports, "__esModule", {
|
|
5
|
-
value: true
|
|
6
|
-
});
|
|
7
|
-
exports.default = void 0;
|
|
8
|
-
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
|
|
9
|
-
var _styles = require("@mui/material/styles");
|
|
10
|
-
var _TerrawareTheme = _interopRequireDefault(require("./style-dictionary-dist/TerrawareTheme"));
|
|
1
|
+
import { createTheme } from '@mui/material/styles';
|
|
2
|
+
import TerrawareTheme from './style-dictionary-dist/TerrawareTheme';
|
|
11
3
|
const defaultTheme = {
|
|
12
4
|
breakpoints: {
|
|
13
5
|
values: {
|
|
@@ -40,7 +32,7 @@ const defaultTheme = {
|
|
|
40
32
|
}
|
|
41
33
|
}
|
|
42
34
|
},
|
|
43
|
-
palette:
|
|
35
|
+
palette: {
|
|
44
36
|
primary: {
|
|
45
37
|
main: '#0067C8'
|
|
46
38
|
},
|
|
@@ -80,7 +72,8 @@ const defaultTheme = {
|
|
|
80
72
|
gray: {
|
|
81
73
|
200: '#CAD2D3',
|
|
82
74
|
800: '#3A4445'
|
|
83
|
-
}
|
|
84
|
-
|
|
75
|
+
},
|
|
76
|
+
...TerrawareTheme.palette
|
|
77
|
+
}
|
|
85
78
|
};
|
|
86
|
-
|
|
79
|
+
export default createTheme(defaultTheme);
|
package/utils/color.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"color.d.ts","sourceRoot":"","sources":["../../src/utils/color.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc,GAAI,KAAK,MAAM,EAAE,SAAS,MAAM,WAK1D,CAAC"}
|
package/utils/color.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import hexRgb from 'hex-rgb';
|
|
2
|
+
export const getRgbaFromHex = (hex, opacity) => {
|
|
3
|
+
const rgba = hexRgb(hex, {
|
|
4
|
+
alpha: opacity,
|
|
5
|
+
format: 'object'
|
|
6
|
+
});
|
|
7
|
+
const {
|
|
8
|
+
red,
|
|
9
|
+
green,
|
|
10
|
+
blue,
|
|
11
|
+
alpha
|
|
12
|
+
} = rgba;
|
|
13
|
+
return `rgba(${red}, ${green}, ${blue}, ${alpha})`;
|
|
14
|
+
};
|
package/utils/date.js
CHANGED
|
@@ -1,12 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
import _ from 'lodash';
|
|
2
|
+
import { DateTime } from 'luxon';
|
|
2
3
|
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
-
Object.defineProperty(exports, "__esModule", {
|
|
5
|
-
value: true
|
|
6
|
-
});
|
|
7
|
-
exports.tz = exports.isInTheFuture = exports.getTodaysDateFormatted = exports.getShortDate = exports.getDate = exports.default = void 0;
|
|
8
|
-
var _lodash = _interopRequireDefault(require("lodash"));
|
|
9
|
-
var _luxon = require("luxon");
|
|
10
4
|
/**
|
|
11
5
|
* Accepted date types for input are:
|
|
12
6
|
* - string for any date ISO string representation
|
|
@@ -18,15 +12,14 @@ var _luxon = require("luxon");
|
|
|
18
12
|
/**
|
|
19
13
|
* Helper util that returns default time zone as a fallback.
|
|
20
14
|
*/
|
|
21
|
-
const tz = timeZoneId => timeZoneId || 'Etc/UTC';
|
|
15
|
+
export const tz = timeZoneId => timeZoneId || 'Etc/UTC';
|
|
22
16
|
|
|
23
17
|
/**
|
|
24
18
|
* Parse a date ISO string with zone implied.
|
|
25
19
|
* eg. '2023-01-10 in 'America/Los_Angeles'
|
|
26
20
|
*/
|
|
27
|
-
exports.tz = tz;
|
|
28
21
|
const getDateFromISOString = (date, timeZoneId) => {
|
|
29
|
-
return
|
|
22
|
+
return DateTime.fromISO(date, {
|
|
30
23
|
zone: tz(timeZoneId)
|
|
31
24
|
});
|
|
32
25
|
};
|
|
@@ -36,7 +29,7 @@ const getDateFromISOString = (date, timeZoneId) => {
|
|
|
36
29
|
*/
|
|
37
30
|
const getDateFromMillis = (date, timeZoneId) => {
|
|
38
31
|
const millis = new Date(date).getTime();
|
|
39
|
-
return
|
|
32
|
+
return DateTime.fromMillis(millis, {
|
|
40
33
|
zone: tz(timeZoneId)
|
|
41
34
|
});
|
|
42
35
|
};
|
|
@@ -54,7 +47,7 @@ const getDisplayValue = date => {
|
|
|
54
47
|
/**
|
|
55
48
|
* Returns <Month> <Year> (eg. July 2023).
|
|
56
49
|
*/
|
|
57
|
-
const getShortDate = date => {
|
|
50
|
+
export const getShortDate = date => {
|
|
58
51
|
if (date.isValid) {
|
|
59
52
|
return date.toFormat('LLLL yyyy');
|
|
60
53
|
}
|
|
@@ -66,8 +59,7 @@ const getShortDate = date => {
|
|
|
66
59
|
* any DateType value passed in (ISO string or epoch milliseconds or DateTime object).
|
|
67
60
|
* Note: the DateTime object input support is mostly for ease of use and will essentially be a pass-through.
|
|
68
61
|
*/
|
|
69
|
-
|
|
70
|
-
const getDate = (date, timeZoneId) => {
|
|
62
|
+
export const getDate = (date, timeZoneId) => {
|
|
71
63
|
if (typeof date === 'string') {
|
|
72
64
|
const fromString = getDateFromISOString(date, timeZoneId);
|
|
73
65
|
if (fromString.isValid) {
|
|
@@ -80,8 +72,8 @@ const getDate = (date, timeZoneId) => {
|
|
|
80
72
|
return fromMillis;
|
|
81
73
|
}
|
|
82
74
|
}
|
|
83
|
-
if (
|
|
84
|
-
return
|
|
75
|
+
if (_.isDate(date) || typeof date === 'string' || typeof date === 'number') {
|
|
76
|
+
return DateTime.fromJSDate(new Date(date), {
|
|
85
77
|
zone: tz(timeZoneId)
|
|
86
78
|
});
|
|
87
79
|
}
|
|
@@ -92,7 +84,6 @@ const getDate = (date, timeZoneId) => {
|
|
|
92
84
|
* Default export function that provides a display value for a date
|
|
93
85
|
* with optional implied time zone.
|
|
94
86
|
*/
|
|
95
|
-
exports.getDate = getDate;
|
|
96
87
|
const getDateDisplayValue = (date, timeZoneId) => {
|
|
97
88
|
if (typeof date === 'string' && date.match(/^\d\d\d\d-\d\d-\d\d$/)) {
|
|
98
89
|
// if already in display format, return as-is, do not apply time zone
|
|
@@ -105,20 +96,18 @@ const getDateDisplayValue = (date, timeZoneId) => {
|
|
|
105
96
|
/**
|
|
106
97
|
* Exported function that returns todays date in a specific (optional) time zone.
|
|
107
98
|
*/
|
|
108
|
-
const getTodaysDateFormatted = timeZoneId => {
|
|
109
|
-
return getDisplayValue(
|
|
99
|
+
export const getTodaysDateFormatted = timeZoneId => {
|
|
100
|
+
return getDisplayValue(DateTime.now().setZone(tz(timeZoneId)));
|
|
110
101
|
};
|
|
111
102
|
|
|
112
103
|
/**
|
|
113
104
|
* Checks if a date is in the future, time zone for date is optional.
|
|
114
105
|
*/
|
|
115
|
-
|
|
116
|
-
const isInTheFuture = (date, timeZoneId) => {
|
|
106
|
+
export const isInTheFuture = (date, timeZoneId) => {
|
|
117
107
|
const d = getDate(date, timeZoneId);
|
|
118
108
|
if (d.isValid) {
|
|
119
109
|
return d.toMillis() > Date.now();
|
|
120
110
|
}
|
|
121
111
|
return false;
|
|
122
112
|
};
|
|
123
|
-
|
|
124
|
-
var _default = exports.default = getDateDisplayValue;
|
|
113
|
+
export default getDateDisplayValue;
|
package/utils/date.test.js
CHANGED
|
@@ -1,87 +1,84 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
4
|
-
var _luxon = require("luxon");
|
|
5
|
-
var _date = _interopRequireWildcard(require("./date"));
|
|
1
|
+
import { DateTime } from 'luxon';
|
|
2
|
+
import getDateDisplayValue, { getTodaysDateFormatted, isInTheFuture } from './date';
|
|
6
3
|
test('isInTheFuture should handle date ISO string and specified time zones', () => {
|
|
7
|
-
expect(
|
|
8
|
-
expect(
|
|
9
|
-
expect(
|
|
4
|
+
expect(isInTheFuture('2023-01-10', 'Asia/Bangkok')).toBe(false);
|
|
5
|
+
expect(isInTheFuture('2023-01-10', 'America/Los_Angeles')).toBe(false);
|
|
6
|
+
expect(isInTheFuture('3023-01-10', 'America/Los_Angeles')).toBe(true);
|
|
10
7
|
});
|
|
11
8
|
test('isInTheFuture should handle date ISO string and default time zone', () => {
|
|
12
|
-
expect(
|
|
13
|
-
expect(
|
|
9
|
+
expect(isInTheFuture('2023-01-10')).toBe(false);
|
|
10
|
+
expect(isInTheFuture('3023-01-10')).toBe(true);
|
|
14
11
|
});
|
|
15
12
|
test('isInTheFuture should handle millis and specified time zones', () => {
|
|
16
|
-
expect(
|
|
17
|
-
expect(
|
|
13
|
+
expect(isInTheFuture(Date.now(), 'Asia/Bangkok')).toBe(false);
|
|
14
|
+
expect(isInTheFuture(new Date('3023-01-10').getTime(), 'Asia/Bangkok')).toBe(true);
|
|
18
15
|
});
|
|
19
16
|
test('isInTheFuture should handle millis and default time zone', () => {
|
|
20
|
-
expect(
|
|
21
|
-
expect(
|
|
17
|
+
expect(isInTheFuture(Date.now())).toBe(false);
|
|
18
|
+
expect(isInTheFuture(new Date('3023-01-10').getTime())).toBe(true);
|
|
22
19
|
});
|
|
23
20
|
test('isInTheFuture should handle JS Date object and specified time zones', () => {
|
|
24
|
-
expect(
|
|
25
|
-
expect(
|
|
21
|
+
expect(isInTheFuture(new Date(), 'Asia/Bangkok')).toBe(false);
|
|
22
|
+
expect(isInTheFuture(new Date('3023-01-10'), 'Asia/Bangkok')).toBe(true);
|
|
26
23
|
});
|
|
27
24
|
test('isInTheFuture should handle JS Date object and default time zone', () => {
|
|
28
|
-
expect(
|
|
29
|
-
expect(
|
|
25
|
+
expect(isInTheFuture(new Date())).toBe(false);
|
|
26
|
+
expect(isInTheFuture(new Date('3023-01-10'))).toBe(true);
|
|
30
27
|
});
|
|
31
28
|
test('isInTheFuture should handle DateTime object and specified time zones', () => {
|
|
32
|
-
expect(
|
|
33
|
-
expect(
|
|
29
|
+
expect(isInTheFuture(DateTime.now(), 'Asia/Bangkok')).toBe(false);
|
|
30
|
+
expect(isInTheFuture(DateTime.fromISO('3023-01-10'), 'Asia/Bangkok')).toBe(true);
|
|
34
31
|
// check that a DateTime with preset zone is a no-op
|
|
35
|
-
expect(
|
|
36
|
-
expect(
|
|
32
|
+
expect(isInTheFuture(DateTime.now().setZone('Asia/Bangkok'), 'Asia/Bangkok')).toBe(false);
|
|
33
|
+
expect(isInTheFuture(DateTime.fromISO('3023-01-10').setZone('Asia/Bangkok'), 'Asia/Bangkok')).toBe(true);
|
|
37
34
|
});
|
|
38
35
|
test('isInTheFuture should handle JS Date object and default time zone', () => {
|
|
39
|
-
expect(
|
|
40
|
-
expect(
|
|
36
|
+
expect(isInTheFuture(DateTime.now())).toBe(false);
|
|
37
|
+
expect(isInTheFuture(DateTime.fromISO('3023-01-10'))).toBe(true);
|
|
41
38
|
});
|
|
42
39
|
test('should show todays date formatted for a time zone', () => {
|
|
43
|
-
const formatted =
|
|
40
|
+
const formatted = getTodaysDateFormatted('Asia/Bangkok');
|
|
44
41
|
expect(!!formatted.match(/\d\d\d\d-\d\d-\d\d/)).toBe(true);
|
|
45
42
|
});
|
|
46
43
|
test('should show todays date formatted for default time zone', () => {
|
|
47
|
-
const formatted =
|
|
44
|
+
const formatted = getTodaysDateFormatted();
|
|
48
45
|
expect(!!formatted.match(/\d\d\d\d-\d\d-\d\d/)).toBe(true);
|
|
49
46
|
});
|
|
50
47
|
test('should return valid date display value for ISO date string with time zones', () => {
|
|
51
|
-
expect((
|
|
52
|
-
expect((
|
|
48
|
+
expect(getDateDisplayValue('2021-08-05T19:39:16Z', 'America/Los_Angeles')).toBe('2021-08-05');
|
|
49
|
+
expect(getDateDisplayValue('2021-08-05T19:39:16Z', 'Asia/Bangkok')).toBe('2021-08-06');
|
|
53
50
|
});
|
|
54
51
|
test('should return valid date display value for ISO date string with default time zone', () => {
|
|
55
|
-
expect((
|
|
52
|
+
expect(getDateDisplayValue('2021-08-05T19:39:16Z')).toBe('2021-08-05');
|
|
56
53
|
});
|
|
57
54
|
test('should return valid date display value for default date ISO string with time zones', () => {
|
|
58
|
-
expect((
|
|
59
|
-
expect((
|
|
55
|
+
expect(getDateDisplayValue('2021-08-05', 'America/Los_Angeles')).toBe('2021-08-05');
|
|
56
|
+
expect(getDateDisplayValue('2021-08-05', 'Asia/Bangkok')).toBe('2021-08-05');
|
|
60
57
|
});
|
|
61
58
|
test('should return valid date display value for default date string with default time zone', () => {
|
|
62
|
-
expect((
|
|
59
|
+
expect(getDateDisplayValue('2021-08-05')).toBe('2021-08-05');
|
|
63
60
|
});
|
|
64
61
|
test('should return valid date display value for millis with default time zone', () => {
|
|
65
|
-
expect((
|
|
62
|
+
expect(getDateDisplayValue(new Date('2021-08-05T19:39:16Z').getTime())).toBe('2021-08-05');
|
|
66
63
|
});
|
|
67
64
|
test('should return valid date display value for JS Date object with default time zone', () => {
|
|
68
|
-
expect((
|
|
65
|
+
expect(getDateDisplayValue(new Date('2021-08-05T19:39:16Z'))).toBe('2021-08-05');
|
|
69
66
|
});
|
|
70
67
|
test('should return valid date display value for DateTime object with default time zone', () => {
|
|
71
|
-
expect((
|
|
68
|
+
expect(getDateDisplayValue(DateTime.fromISO('2021-08-05T19:39:16Z'))).toBe('2021-08-05');
|
|
72
69
|
});
|
|
73
70
|
test('should return valid date display value for millis with time zones', () => {
|
|
74
|
-
expect((
|
|
75
|
-
expect((
|
|
71
|
+
expect(getDateDisplayValue(new Date('2021-08-05T19:39:16Z').getTime(), 'America/Los_Angeles')).toBe('2021-08-05');
|
|
72
|
+
expect(getDateDisplayValue(new Date('2021-08-05T19:39:16Z').getTime(), 'Asia/Bangkok')).toBe('2021-08-06');
|
|
76
73
|
});
|
|
77
74
|
test('should return valid date display value for JS Date object with time zones', () => {
|
|
78
|
-
expect((
|
|
79
|
-
expect((
|
|
75
|
+
expect(getDateDisplayValue(new Date('2021-08-05T19:39:16Z'), 'America/Los_Angeles')).toBe('2021-08-05');
|
|
76
|
+
expect(getDateDisplayValue(new Date('2021-08-05T19:39:16Z'), 'Asia/Bangkok')).toBe('2021-08-06');
|
|
80
77
|
});
|
|
81
78
|
test('should return valid date display value for DateTime object with time zones', () => {
|
|
82
|
-
expect((
|
|
83
|
-
expect((
|
|
79
|
+
expect(getDateDisplayValue(DateTime.fromISO('2021-08-05T19:39:16Z'), 'America/Los_Angeles')).toBe('2021-08-05');
|
|
80
|
+
expect(getDateDisplayValue(DateTime.fromISO('2021-08-05T19:39:16Z'), 'Asia/Bangkok')).toBe('2021-08-06');
|
|
84
81
|
// check that a DateTime with preset zone is a no-op
|
|
85
|
-
expect((
|
|
86
|
-
expect((
|
|
82
|
+
expect(getDateDisplayValue(DateTime.fromISO('2021-08-05T19:39:16Z').setZone('America/Los_Angeles'), 'America/Los_Angeles')).toBe('2021-08-05');
|
|
83
|
+
expect(getDateDisplayValue(DateTime.fromISO('2021-08-05T19:39:16Z').setZone('America/Los_Angeles'), 'Asia/Bangkok')).toBe('2021-08-06');
|
|
87
84
|
});
|
package/utils/index.js
CHANGED
|
@@ -1,53 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
Object.defineProperty(exports, "getDate", {
|
|
9
|
-
enumerable: true,
|
|
10
|
-
get: function () {
|
|
11
|
-
return _date.getDate;
|
|
12
|
-
}
|
|
13
|
-
});
|
|
14
|
-
Object.defineProperty(exports, "getDateDisplayValue", {
|
|
15
|
-
enumerable: true,
|
|
16
|
-
get: function () {
|
|
17
|
-
return _date.default;
|
|
18
|
-
}
|
|
19
|
-
});
|
|
20
|
-
Object.defineProperty(exports, "getTodaysDateFormatted", {
|
|
21
|
-
enumerable: true,
|
|
22
|
-
get: function () {
|
|
23
|
-
return _date.getTodaysDateFormatted;
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
|
-
Object.defineProperty(exports, "isInTheFuture", {
|
|
27
|
-
enumerable: true,
|
|
28
|
-
get: function () {
|
|
29
|
-
return _date.isInTheFuture;
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
Object.defineProperty(exports, "isWhitespaces", {
|
|
33
|
-
enumerable: true,
|
|
34
|
-
get: function () {
|
|
35
|
-
return _text.default;
|
|
36
|
-
}
|
|
37
|
-
});
|
|
38
|
-
Object.defineProperty(exports, "preventDefaultEvent", {
|
|
39
|
-
enumerable: true,
|
|
40
|
-
get: function () {
|
|
41
|
-
return _preventDefaultEvent.default;
|
|
42
|
-
}
|
|
43
|
-
});
|
|
44
|
-
Object.defineProperty(exports, "useDeviceInfo", {
|
|
45
|
-
enumerable: true,
|
|
46
|
-
get: function () {
|
|
47
|
-
return _useDeviceInfo.default;
|
|
48
|
-
}
|
|
49
|
-
});
|
|
50
|
-
var _date = _interopRequireWildcard(require("./date"));
|
|
51
|
-
var _preventDefaultEvent = _interopRequireDefault(require("./preventDefaultEvent"));
|
|
52
|
-
var _text = _interopRequireDefault(require("./text"));
|
|
53
|
-
var _useDeviceInfo = _interopRequireDefault(require("./useDeviceInfo"));
|
|
1
|
+
import getDateDisplayValue, { getDate, getTodaysDateFormatted, isInTheFuture } from './date';
|
|
2
|
+
import preventDefaultEvent from './preventDefaultEvent';
|
|
3
|
+
import isWhitespaces from './text';
|
|
4
|
+
import useDeviceInfo from './useDeviceInfo';
|
|
5
|
+
export { getDate, getDateDisplayValue, getTodaysDateFormatted, isInTheFuture, isWhitespaces, preventDefaultEvent, useDeviceInfo };
|
package/utils/text.js
CHANGED
|
@@ -1,11 +1,5 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.titleCase = exports.default = void 0;
|
|
7
1
|
const isWhitespaces = str => str.match(/^\s+$/);
|
|
8
|
-
const titleCase = str => str.split(' ').map(word => {
|
|
2
|
+
export const titleCase = str => str.split(' ').map(word => {
|
|
9
3
|
if (word !== word.toUpperCase()) {
|
|
10
4
|
const lowerCaseWord = word.toLowerCase();
|
|
11
5
|
return lowerCaseWord.replace(lowerCaseWord.charAt(0), lowerCaseWord.charAt(0).toUpperCase());
|
|
@@ -13,5 +7,4 @@ const titleCase = str => str.split(' ').map(word => {
|
|
|
13
7
|
return word;
|
|
14
8
|
}
|
|
15
9
|
}).join(' ');
|
|
16
|
-
|
|
17
|
-
var _default = exports.default = isWhitespaces;
|
|
10
|
+
export default isWhitespaces;
|
package/utils/text.test.js
CHANGED
|
@@ -1,23 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var _text = require("./text");
|
|
1
|
+
import { titleCase } from './text';
|
|
4
2
|
test('titleCase for a single word', () => {
|
|
5
|
-
const lowerCaseWord =
|
|
3
|
+
const lowerCaseWord = titleCase('species');
|
|
6
4
|
expect(lowerCaseWord === 'Species').toBe(true);
|
|
7
|
-
const capitalizedWord =
|
|
5
|
+
const capitalizedWord = titleCase('Species');
|
|
8
6
|
expect(capitalizedWord === 'Species').toBe(true);
|
|
9
|
-
const allCapsWord =
|
|
7
|
+
const allCapsWord = titleCase('SPECIES');
|
|
10
8
|
expect(allCapsWord === 'SPECIES').toBe(true);
|
|
11
|
-
const reverseCapWord =
|
|
9
|
+
const reverseCapWord = titleCase('sPECIES');
|
|
12
10
|
expect(reverseCapWord === 'Species').toBe(true);
|
|
13
11
|
});
|
|
14
12
|
test('titleCase for multiple words', () => {
|
|
15
|
-
const lowerCaseString =
|
|
13
|
+
const lowerCaseString = titleCase('common name');
|
|
16
14
|
expect(lowerCaseString === 'Common Name').toBe(true);
|
|
17
|
-
const capitalizedString =
|
|
15
|
+
const capitalizedString = titleCase('Common Name');
|
|
18
16
|
expect(capitalizedString === 'Common Name').toBe(true);
|
|
19
|
-
const allCapsString =
|
|
17
|
+
const allCapsString = titleCase('common NAME');
|
|
20
18
|
expect(allCapsString === 'Common NAME').toBe(true);
|
|
21
|
-
const reverseCapString =
|
|
19
|
+
const reverseCapString = titleCase('cOMMON nAME');
|
|
22
20
|
expect(reverseCapString === 'Common Name').toBe(true);
|
|
23
21
|
});
|
package/utils/useDeviceInfo.js
CHANGED
|
@@ -1,10 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
import { useMediaQuery } from 'react-responsive';
|
|
2
2
|
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.default = void 0;
|
|
7
|
-
var _reactResponsive = require("react-responsive");
|
|
8
3
|
/**
|
|
9
4
|
* Device widths categorized for our purposes.
|
|
10
5
|
* Device widths
|
|
@@ -31,29 +26,28 @@ var _reactResponsive = require("react-responsive");
|
|
|
31
26
|
* if there's a change in any of our interested device properties.
|
|
32
27
|
*/
|
|
33
28
|
|
|
34
|
-
const useDeviceInfo =
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
} = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
29
|
+
const useDeviceInfo = ({
|
|
30
|
+
onChange
|
|
31
|
+
} = {}) => {
|
|
38
32
|
const deviceChangeCallback = matches => {
|
|
39
33
|
if (matches && onChange) {
|
|
40
34
|
onChange();
|
|
41
35
|
}
|
|
42
36
|
};
|
|
43
|
-
const isDesktop =
|
|
37
|
+
const isDesktop = useMediaQuery({
|
|
44
38
|
minWidth: 1024
|
|
45
39
|
}, undefined, deviceChangeCallback);
|
|
46
|
-
const isTablet =
|
|
40
|
+
const isTablet = useMediaQuery({
|
|
47
41
|
maxWidth: 1023,
|
|
48
42
|
minWidth: 768
|
|
49
43
|
}, undefined, deviceChangeCallback);
|
|
50
|
-
const isMobile =
|
|
44
|
+
const isMobile = useMediaQuery({
|
|
51
45
|
maxWidth: 767
|
|
52
46
|
}, undefined, deviceChangeCallback);
|
|
53
|
-
const isPortrait =
|
|
47
|
+
const isPortrait = useMediaQuery({
|
|
54
48
|
orientation: 'portrait'
|
|
55
49
|
}, undefined, deviceChangeCallback);
|
|
56
|
-
const isRetina =
|
|
50
|
+
const isRetina = useMediaQuery({
|
|
57
51
|
query: '(min-resolution: 2dppx)'
|
|
58
52
|
}, undefined, deviceChangeCallback);
|
|
59
53
|
const getDeviceType = () => {
|
|
@@ -82,4 +76,4 @@ const useDeviceInfo = function () {
|
|
|
82
76
|
isLandscape: !isPortrait
|
|
83
77
|
};
|
|
84
78
|
};
|
|
85
|
-
|
|
79
|
+
export default useDeviceInfo;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import Annotation from './components/VirtualWalkthrough/Annotation';
|
|
2
|
+
import AnnotationEditPane from './components/VirtualWalkthrough/AnnotationEditPane';
|
|
3
|
+
import AnnotationPanel from './components/VirtualWalkthrough/AnnotationPanel';
|
|
4
|
+
import Application from './components/VirtualWalkthrough/Application';
|
|
5
|
+
import { AutoRotator } from './components/VirtualWalkthrough/AutoRotator';
|
|
6
|
+
import BlockingSpinner from './components/VirtualWalkthrough/BlockingSpinner';
|
|
7
|
+
import BoundaryRing from './components/VirtualWalkthrough/BoundaryRing';
|
|
8
|
+
import CameraInfo from './components/VirtualWalkthrough/CameraInfo';
|
|
9
|
+
import ControlsInfoPane from './components/VirtualWalkthrough/ControlsInfoPane';
|
|
10
|
+
import GradientSky from './components/VirtualWalkthrough/GradientSky';
|
|
11
|
+
import SplatControls from './components/VirtualWalkthrough/SplatControls';
|
|
12
|
+
import SplatCrop from './components/VirtualWalkthrough/SplatCrop';
|
|
13
|
+
import SplatFadeCrop from './components/VirtualWalkthrough/SplatFadeCrop';
|
|
14
|
+
import SplatModel from './components/VirtualWalkthrough/SplatModel';
|
|
15
|
+
import SplatRevealRain from './components/VirtualWalkthrough/SplatRevealRain';
|
|
16
|
+
import { TfAnnotationManager } from './components/VirtualWalkthrough/TfAnnotationManager';
|
|
17
|
+
import { TfXrNavigation } from './components/VirtualWalkthrough/TfXrNavigation';
|
|
18
|
+
import { BoundaryRingScript, boundaryRingMesh } from './components/VirtualWalkthrough/boundary-ring';
|
|
19
|
+
import { computeGroundPlane, yOnPlane } from './components/VirtualWalkthrough/groundPlane';
|
|
20
|
+
import { WalkthroughCamera } from './components/VirtualWalkthrough/walkthrough-camera';
|
|
21
|
+
export type { AnnotationProps, AnnotationIconType } from './components/VirtualWalkthrough/Annotation';
|
|
22
|
+
export type { AnnotationEditPaneStrings } from './components/VirtualWalkthrough/AnnotationEditPane';
|
|
23
|
+
export type { CameraInfoStrings, CameraState } from './components/VirtualWalkthrough/CameraInfo';
|
|
24
|
+
export type { ControlsInfoPaneStrings } from './components/VirtualWalkthrough/ControlsInfoPane';
|
|
25
|
+
export type { SplatControlsProps, SplatControlsStrings } from './components/VirtualWalkthrough/SplatControls';
|
|
26
|
+
export type { BoundaryRingGeometry, BoundaryRingGeometryParams } from './components/VirtualWalkthrough/boundary-ring';
|
|
27
|
+
export type { GroundPlane } from './components/VirtualWalkthrough/groundPlane';
|
|
28
|
+
export type { BoundaryRingProps } from './components/VirtualWalkthrough/BoundaryRing';
|
|
29
|
+
export type { SplatModelProps } from './components/VirtualWalkthrough/SplatModel';
|
|
30
|
+
export { Annotation, AnnotationEditPane, AnnotationPanel, Application, AutoRotator, BlockingSpinner, BoundaryRing, boundaryRingMesh, BoundaryRingScript, CameraInfo, computeGroundPlane, ControlsInfoPane, GradientSky, SplatControls, SplatCrop, SplatFadeCrop, SplatModel, SplatRevealRain, TfAnnotationManager, TfXrNavigation, WalkthroughCamera, yOnPlane, };
|
|
31
|
+
//# sourceMappingURL=virtualWalkthrough.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"virtualWalkthrough.d.ts","sourceRoot":"","sources":["../src/virtualWalkthrough.ts"],"names":[],"mappings":"AAOA,OAAO,UAAU,MAAM,4CAA4C,CAAC;AACpE,OAAO,kBAAkB,MAAM,oDAAoD,CAAC;AACpF,OAAO,eAAe,MAAM,iDAAiD,CAAC;AAC9E,OAAO,WAAW,MAAM,6CAA6C,CAAC;AACtE,OAAO,EAAE,WAAW,EAAE,MAAM,6CAA6C,CAAC;AAC1E,OAAO,eAAe,MAAM,iDAAiD,CAAC;AAC9E,OAAO,YAAY,MAAM,8CAA8C,CAAC;AACxE,OAAO,UAAU,MAAM,4CAA4C,CAAC;AACpE,OAAO,gBAAgB,MAAM,kDAAkD,CAAC;AAChF,OAAO,WAAW,MAAM,6CAA6C,CAAC;AACtE,OAAO,aAAa,MAAM,+CAA+C,CAAC;AAC1E,OAAO,SAAS,MAAM,2CAA2C,CAAC;AAClE,OAAO,aAAa,MAAM,+CAA+C,CAAC;AAC1E,OAAO,UAAU,MAAM,4CAA4C,CAAC;AACpE,OAAO,eAAe,MAAM,iDAAiD,CAAC;AAC9E,OAAO,EAAE,mBAAmB,EAAE,MAAM,qDAAqD,CAAC;AAC1F,OAAO,EAAE,cAAc,EAAE,MAAM,gDAAgD,CAAC;AAChF,OAAO,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,MAAM,+CAA+C,CAAC;AACrG,OAAO,EAAE,kBAAkB,EAAE,QAAQ,EAAE,MAAM,6CAA6C,CAAC;AAC3F,OAAO,EAAE,iBAAiB,EAAE,MAAM,oDAAoD,CAAC;AAEvF,YAAY,EAAE,eAAe,EAAE,kBAAkB,EAAE,MAAM,4CAA4C,CAAC;AACtG,YAAY,EAAE,yBAAyB,EAAE,MAAM,oDAAoD,CAAC;AACpG,YAAY,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AACjG,YAAY,EAAE,uBAAuB,EAAE,MAAM,kDAAkD,CAAC;AAChG,YAAY,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,MAAM,+CAA+C,CAAC;AAC9G,YAAY,EAAE,oBAAoB,EAAE,0BAA0B,EAAE,MAAM,+CAA+C,CAAC;AACtH,YAAY,EAAE,WAAW,EAAE,MAAM,6CAA6C,CAAC;AAC/E,YAAY,EAAE,iBAAiB,EAAE,MAAM,8CAA8C,CAAC;AACtF,YAAY,EAAE,eAAe,EAAE,MAAM,4CAA4C,CAAC;AAElF,OAAO,EACL,UAAU,EACV,kBAAkB,EAClB,eAAe,EACf,WAAW,EACX,WAAW,EACX,eAAe,EACf,YAAY,EACZ,gBAAgB,EAChB,kBAAkB,EAClB,UAAU,EACV,kBAAkB,EAClB,gBAAgB,EAChB,WAAW,EACX,aAAa,EACb,SAAS,EACT,aAAa,EACb,UAAU,EACV,eAAe,EACf,mBAAmB,EACnB,cAAc,EACd,iBAAiB,EACjB,QAAQ,GACT,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Public entry point for the PlayCanvas-based virtual walkthrough components.
|
|
3
|
+
*
|
|
4
|
+
* These are kept out of the main index so that importing the core component
|
|
5
|
+
* library does not pull in playcanvas. Import them from
|
|
6
|
+
* `@terraware/web-components/virtualWalkthrough`.
|
|
7
|
+
*/
|
|
8
|
+
import Annotation from './components/VirtualWalkthrough/Annotation';
|
|
9
|
+
import AnnotationEditPane from './components/VirtualWalkthrough/AnnotationEditPane';
|
|
10
|
+
import AnnotationPanel from './components/VirtualWalkthrough/AnnotationPanel';
|
|
11
|
+
import Application from './components/VirtualWalkthrough/Application';
|
|
12
|
+
import { AutoRotator } from './components/VirtualWalkthrough/AutoRotator';
|
|
13
|
+
import BlockingSpinner from './components/VirtualWalkthrough/BlockingSpinner';
|
|
14
|
+
import BoundaryRing from './components/VirtualWalkthrough/BoundaryRing';
|
|
15
|
+
import CameraInfo from './components/VirtualWalkthrough/CameraInfo';
|
|
16
|
+
import ControlsInfoPane from './components/VirtualWalkthrough/ControlsInfoPane';
|
|
17
|
+
import GradientSky from './components/VirtualWalkthrough/GradientSky';
|
|
18
|
+
import SplatControls from './components/VirtualWalkthrough/SplatControls';
|
|
19
|
+
import SplatCrop from './components/VirtualWalkthrough/SplatCrop';
|
|
20
|
+
import SplatFadeCrop from './components/VirtualWalkthrough/SplatFadeCrop';
|
|
21
|
+
import SplatModel from './components/VirtualWalkthrough/SplatModel';
|
|
22
|
+
import SplatRevealRain from './components/VirtualWalkthrough/SplatRevealRain';
|
|
23
|
+
import { TfAnnotationManager } from './components/VirtualWalkthrough/TfAnnotationManager';
|
|
24
|
+
import { TfXrNavigation } from './components/VirtualWalkthrough/TfXrNavigation';
|
|
25
|
+
import { BoundaryRingScript, boundaryRingMesh } from './components/VirtualWalkthrough/boundary-ring';
|
|
26
|
+
import { computeGroundPlane, yOnPlane } from './components/VirtualWalkthrough/groundPlane';
|
|
27
|
+
import { WalkthroughCamera } from './components/VirtualWalkthrough/walkthrough-camera';
|
|
28
|
+
export { Annotation, AnnotationEditPane, AnnotationPanel, Application, AutoRotator, BlockingSpinner, BoundaryRing, boundaryRingMesh, BoundaryRingScript, CameraInfo, computeGroundPlane, ControlsInfoPane, GradientSky, SplatControls, SplatCrop, SplatFadeCrop, SplatModel, SplatRevealRain, TfAnnotationManager, TfXrNavigation, WalkthroughCamera, yOnPlane };
|