@clikvn/showroom-visualizer 0.2.2-dev-14 → 0.2.3-dev-01

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.
Files changed (48) hide show
  1. package/README.md +31 -31
  2. package/base.json +21 -21
  3. package/dist/components/SkinLayer/Drawer/PoiHeader/index.d.ts +16 -0
  4. package/dist/components/SkinLayer/Drawer/PoiHeader/index.d.ts.map +1 -0
  5. package/dist/components/SkinLayer/Drawer/index.d.ts +29 -0
  6. package/dist/components/SkinLayer/Drawer/index.d.ts.map +1 -0
  7. package/dist/components/SkinLayer/PlayAll/index.d.ts +8 -0
  8. package/dist/components/SkinLayer/PlayAll/index.d.ts.map +1 -0
  9. package/dist/components/SkinLayer/PlayBar/index.d.ts.map +1 -1
  10. package/dist/features/VirtualTourVisualizer/index.d.ts +20 -0
  11. package/dist/features/VirtualTourVisualizer/index.d.ts.map +1 -0
  12. package/dist/features/VirtualTourVisualizerUI/index.d.ts +17 -0
  13. package/dist/features/VirtualTourVisualizerUI/index.d.ts.map +1 -0
  14. package/dist/fonts/icomoon.svg +633 -633
  15. package/dist/index.html +10 -85
  16. package/dist/web.d.ts.map +1 -1
  17. package/dist/web.js +1 -1
  18. package/package.json +124 -124
  19. package/rollup.config.js +97 -97
  20. package/tailwind.config.cjs +151 -151
  21. package/.claude/settings.local.json +0 -19
  22. package/dist/components/SkinLayer/DefaultLayout/index.d.ts +0 -8
  23. package/dist/components/SkinLayer/DefaultLayout/index.d.ts.map +0 -1
  24. package/dist/context/CustomLayoutContext.d.ts +0 -20
  25. package/dist/context/CustomLayoutContext.d.ts.map +0 -1
  26. package/dist/context/SwizzleContext.d.ts +0 -21
  27. package/dist/context/SwizzleContext.d.ts.map +0 -1
  28. package/dist/hooks/headless/index.d.ts +0 -150
  29. package/dist/hooks/headless/index.d.ts.map +0 -1
  30. package/dist/hooks/headless/useFloorplanControl.d.ts +0 -18
  31. package/dist/hooks/headless/useFloorplanControl.d.ts.map +0 -1
  32. package/dist/hooks/headless/usePOIInteraction.d.ts +0 -23
  33. package/dist/hooks/headless/usePOIInteraction.d.ts.map +0 -1
  34. package/dist/hooks/headless/useScenarioControl.d.ts +0 -22
  35. package/dist/hooks/headless/useScenarioControl.d.ts.map +0 -1
  36. package/dist/hooks/headless/useSceneNavigation.d.ts +0 -26
  37. package/dist/hooks/headless/useSceneNavigation.d.ts.map +0 -1
  38. package/dist/hooks/headless/useTourCore.d.ts +0 -23
  39. package/dist/hooks/headless/useTourCore.d.ts.map +0 -1
  40. package/dist/hooks/headless/useViewportControl.d.ts +0 -22
  41. package/dist/hooks/headless/useViewportControl.d.ts.map +0 -1
  42. package/dist/index.js +0 -1
  43. package/dist/types/custom-layout.d.ts +0 -63
  44. package/dist/types/custom-layout.d.ts.map +0 -1
  45. package/dist/types/swizzle.d.ts +0 -59
  46. package/dist/types/swizzle.d.ts.map +0 -1
  47. /package/dist/features/ShowroomVisualizer/{CssStyles.d.ts → cssStyles.d.ts} +0 -0
  48. /package/dist/features/ShowroomVisualizer/{CssStyles.d.ts.map → cssStyles.d.ts.map} +0 -0
package/README.md CHANGED
@@ -1,32 +1,32 @@
1
- <!-- markdownlint-disable MD030 -->
2
-
3
- # showroom-visualizer
4
-
5
- Javascript library to display Clik Showroom Visualizer with UI on your website
6
-
7
- ```html
8
- <!-- public/index.html -->
9
- <script type="module">
10
- import ShowroomVisualizer from 'http://localhost:3000/web.js';
11
- ShowroomVisualizer.initVisualizer({
12
- apiHost: 'https://ci-api.clik.vn/vt360',
13
- config: {
14
- tourCode: 'TOUR_FXYCEN7ZZVW6',
15
- language: 'EN'
16
- },
17
- onLoaded: tool => {
18
- window.tool = tool;
19
- },
20
- mobile: false
21
- });
22
- </script>
23
- <div style="width: 100vw; height: 100vh">
24
- <showroom-visualizer></showroom-visualizer>
25
- </div>
26
- ```
27
-
28
-
29
-
30
-
31
- add <Scripts /> in ShowroomVisualizer load js ÂR
1
+ <!-- markdownlint-disable MD030 -->
2
+
3
+ # showroom-visualizer
4
+
5
+ Javascript library to display Clik Showroom Visualizer with UI on your website
6
+
7
+ ```html
8
+ <!-- public/index.html -->
9
+ <script type="module">
10
+ import ShowroomVisualizer from 'http://localhost:3000/web.js';
11
+ ShowroomVisualizer.initVisualizer({
12
+ apiHost: 'https://ci-api.clik.vn/vt360',
13
+ config: {
14
+ tourCode: 'TOUR_FXYCEN7ZZVW6',
15
+ language: 'EN'
16
+ },
17
+ onLoaded: tool => {
18
+ window.tool = tool;
19
+ },
20
+ mobile: false
21
+ });
22
+ </script>
23
+ <div style="width: 100vw; height: 100vh">
24
+ <showroom-visualizer></showroom-visualizer>
25
+ </div>
26
+ ```
27
+
28
+
29
+
30
+
31
+ add <Scripts /> in ShowroomVisualizer load js ÂR
32
32
  serve dist --cors
package/base.json CHANGED
@@ -1,21 +1,21 @@
1
- {
2
- "$schema": "https://json.schemastore.org/tsconfig",
3
- "display": "Default",
4
- "compilerOptions": {
5
- "composite": false,
6
- "declaration": true,
7
- "declarationMap": true,
8
- "esModuleInterop": true,
9
- "forceConsistentCasingInFileNames": true,
10
- "inlineSources": false,
11
- "isolatedModules": true,
12
- "moduleResolution": "node",
13
- "noUnusedLocals": false,
14
- "noUnusedParameters": false,
15
- "preserveWatchOutput": true,
16
- "skipLibCheck": true,
17
- "strict": true,
18
- "downlevelIteration": true
19
- },
20
- "exclude": ["node_modules"]
21
- }
1
+ {
2
+ "$schema": "https://json.schemastore.org/tsconfig",
3
+ "display": "Default",
4
+ "compilerOptions": {
5
+ "composite": false,
6
+ "declaration": true,
7
+ "declarationMap": true,
8
+ "esModuleInterop": true,
9
+ "forceConsistentCasingInFileNames": true,
10
+ "inlineSources": false,
11
+ "isolatedModules": true,
12
+ "moduleResolution": "node",
13
+ "noUnusedLocals": false,
14
+ "noUnusedParameters": false,
15
+ "preserveWatchOutput": true,
16
+ "skipLibCheck": true,
17
+ "strict": true,
18
+ "downlevelIteration": true
19
+ },
20
+ "exclude": ["node_modules"]
21
+ }
@@ -0,0 +1,16 @@
1
+ import { FC } from 'react';
2
+ type PoiHeaderPropsTypes = {
3
+ title: string;
4
+ brand?: string;
5
+ rating?: number;
6
+ price?: number;
7
+ salePrice?: number;
8
+ currencyUnit?: string;
9
+ unit?: string;
10
+ onShare?: () => void;
11
+ onClose?: () => void;
12
+ onPlay?: () => void;
13
+ };
14
+ declare const PoiHeader: FC<PoiHeaderPropsTypes>;
15
+ export default PoiHeader;
16
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/SkinLayer/Drawer/PoiHeader/index.tsx"],"names":[],"mappings":"AAEA,OAAc,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAQlC,KAAK,mBAAmB,GAAG;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC;AAEF,QAAA,MAAM,SAAS,EAAE,EAAE,CAAC,mBAAmB,CAwGtC,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -0,0 +1,29 @@
1
+ import { DrawerProps } from 'antd/lib/drawer';
2
+ import { CSSProperties, ReactNode } from 'react';
3
+ export type CommandTypes = {
4
+ icon: string;
5
+ onClick: () => void;
6
+ };
7
+ /**
8
+ * commands is actions list on side-in header
9
+ */
10
+ interface DrawerPropsType extends DrawerProps {
11
+ enableAutoPlay?: boolean;
12
+ enableShare?: boolean;
13
+ title?: string;
14
+ children?: ReactNode;
15
+ header?: ReactNode;
16
+ subHeader?: ReactNode;
17
+ loadingScenario?: boolean;
18
+ commands?: CommandTypes[] | null;
19
+ showHeader?: boolean;
20
+ closeStyle?: CSSProperties;
21
+ onBack?: () => void;
22
+ onClose?: () => void;
23
+ onClickAutoPlay?: () => void;
24
+ onClickShare?: () => void;
25
+ onClickContainer?: () => void;
26
+ }
27
+ declare const _default: import("react").NamedExoticComponent<DrawerPropsType>;
28
+ export default _default;
29
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/SkinLayer/Drawer/index.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAG9C,OAAO,EAAE,aAAa,EAAY,SAAS,EAAoB,MAAM,OAAO,CAAC;AAI7E,MAAM,MAAM,YAAY,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,IAAI,CAAA;CAAE,CAAC;AAEjE;;GAEG;AACH,UAAU,eAAgB,SAAQ,WAAW;IAC3C,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,QAAQ,CAAC,EAAE,YAAY,EAAE,GAAG,IAAI,CAAC;IACjC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,aAAa,CAAC;IAC3B,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;IAC7B,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;CAC/B;;AA4ND,wBAAqC"}
@@ -0,0 +1,8 @@
1
+ import { FC } from 'react';
2
+ export type PlayAllPropsType = {
3
+ onClickAutoPlay?: () => void;
4
+ loading?: boolean;
5
+ };
6
+ declare const PlayAll: FC<PlayAllPropsType>;
7
+ export default PlayAll;
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/SkinLayer/PlayAll/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAI3B,MAAM,MAAM,gBAAgB,GAAG;IAC7B,eAAe,CAAC,EAAE,MAAM,IAAI,CAAC;IAC7B,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,CAAC;AAIF,QAAA,MAAM,OAAO,EAAE,EAAE,CAAC,gBAAgB,CAoCjC,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/SkinLayer/PlayBar/index.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,EAAE,EAAoD,MAAM,OAAO,CAAC;AAc7E,QAAA,MAAM,OAAO,EAAE,EAkUd,CAAC;AAEF,eAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/SkinLayer/PlayBar/index.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,EAAE,EAA4C,MAAM,OAAO,CAAC;AAcrE,QAAA,MAAM,OAAO,EAAE,EAgUd,CAAC;AAEF,eAAe,OAAO,CAAC"}
@@ -0,0 +1,20 @@
1
+ import { FC } from 'react';
2
+ import Poi from '../../models/Visualizer/Poi/Poi';
3
+ import Tour from '../../models/Visualizer/Tour';
4
+ type VirtualTourVisualizerProps = {
5
+ elementId?: string;
6
+ apiHost?: string;
7
+ config?: {
8
+ tourCode?: string;
9
+ language?: string;
10
+ startScene?: string;
11
+ hLookAt?: number;
12
+ vLookAt?: number;
13
+ } & Record<string, unknown>;
14
+ onTourLoaded?: (tour: Tour) => void;
15
+ onPoiClicked?: (poi?: Poi) => void;
16
+ onPinActionClicked?: (key: string) => void;
17
+ };
18
+ declare const VirtualTourVisualizer: FC<VirtualTourVisualizerProps>;
19
+ export default VirtualTourVisualizer;
20
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/features/VirtualTourVisualizer/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAI3B,OAAO,GAAG,MAAM,iCAAiC,CAAC;AAClD,OAAO,IAAI,MAAM,8BAA8B,CAAC;AAEhD,KAAK,0BAA0B,GAAG;IAChC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE;QACP,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC5B,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,IAAI,CAAC;IACpC,YAAY,CAAC,EAAE,CAAC,GAAG,CAAC,EAAE,GAAG,KAAK,IAAI,CAAC;IACnC,kBAAkB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;CAC5C,CAAC;AACF,QAAA,MAAM,qBAAqB,EAAE,EAAE,CAAC,0BAA0B,CAmBzD,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
@@ -0,0 +1,17 @@
1
+ import { FC } from 'react';
2
+ type VirtualTourVisualizerProps = {
3
+ elementId?: string;
4
+ apiHost?: string;
5
+ mobile: boolean;
6
+ config?: {
7
+ tourCode?: string;
8
+ language?: string;
9
+ startScene?: string;
10
+ hLookAt?: number;
11
+ vLookAt?: number;
12
+ } & Record<string, unknown>;
13
+ tourLoaded?: boolean;
14
+ };
15
+ declare const VirtualTourVisualizerUI: FC<VirtualTourVisualizerProps>;
16
+ export default VirtualTourVisualizerUI;
17
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/features/VirtualTourVisualizerUI/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAK3B,KAAK,0BAA0B,GAAG;IAChC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,MAAM,CAAC,EAAE;QACP,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAE5B,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,CAAC;AACF,QAAA,MAAM,uBAAuB,EAAE,EAAE,CAAC,0BAA0B,CAoB3D,CAAC;AAEF,eAAe,uBAAuB,CAAC"}