js-cloudimage-360-view 4.5.4 → 4.7.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/README.md CHANGED
@@ -82,7 +82,7 @@ JS Cloudimage 360 View enables you to create stunning, interactive 360-degree pr
82
82
  | **Touch & Drag** | Intuitive mouse and touch controls with inertia/momentum |
83
83
  | **Pinch-to-Zoom** | Natural pinch gesture zooming on mobile devices |
84
84
  | **Autoplay** | Automatic rotation with configurable behavior and direction |
85
- | **Zoom** | Pointer zoom and magnifier glass for detailed views |
85
+ | **Zoom** | Double-click, Ctrl+scroll, or pinch-to-zoom with pan controls |
86
86
  | **Fullscreen** | Immersive fullscreen mode with ESC key support |
87
87
  | **Hotspots** | Interactive markers with tooltips for highlighting features |
88
88
  | **Keyboard Navigation** | Arrow key support for accessibility |
@@ -99,7 +99,7 @@ Add the library via CDN and create your first 360 viewer in seconds:
99
99
 
100
100
  ```html
101
101
  <!-- Add the library (CSS is auto-injected) -->
102
- <script src="https://scaleflex.cloudimg.io/v7/plugins/js-cloudimage-360-view/4.5.3/js-cloudimage-360-view.min.js?vh=35cf56&func=proxy"></script>
102
+ <script src="https://scaleflex.cloudimg.io/v7/plugins/js-cloudimage-360-view/4.7.0/js-cloudimage-360-view.min.js?vh=e61697&func=proxy"></script>
103
103
 
104
104
  <!-- Create a container with data attributes -->
105
105
  <div
@@ -123,7 +123,7 @@ Add the library via CDN and create your first 360 viewer in seconds:
123
123
  ### Option 1: CDN (Recommended for Quick Setup)
124
124
 
125
125
  ```html
126
- <script src="https://scaleflex.cloudimg.io/v7/plugins/js-cloudimage-360-view/4.5.3/js-cloudimage-360-view.min.js?vh=35cf56&func=proxy"></script>
126
+ <script src="https://scaleflex.cloudimg.io/v7/plugins/js-cloudimage-360-view/4.7.0/js-cloudimage-360-view.min.js?vh=e61697&func=proxy"></script>
127
127
  ```
128
128
 
129
129
  > **Note:** CSS is automatically injected by the script - no separate stylesheet needed.
@@ -165,7 +165,7 @@ The simplest way to create a 360 viewer using HTML data attributes:
165
165
  data-amount-x="36"
166
166
  data-autoplay
167
167
  data-fullscreen
168
- data-magnifier="2"
168
+ data-zoom-max="3"
169
169
  ></div>
170
170
 
171
171
  <script>
@@ -191,8 +191,7 @@ const config = {
191
191
  speed: 100,
192
192
  dragSpeed: 150,
193
193
  fullscreen: true,
194
- magnifier: 2,
195
- pointerZoom: 2,
194
+ zoomMax: 3,
196
195
  inertia: true,
197
196
 
198
197
  // Event callbacks
@@ -436,8 +435,11 @@ All options can be set via JavaScript config or HTML data attributes.
436
435
  |--------|----------------|---------|-------------|
437
436
  | `aspectRatio` | `data-aspect-ratio` | `null` | Aspect ratio for the container (e.g., `"16/9"`, `"4/3"`, `"1/1"`) |
438
437
  | `fullscreen` | `data-fullscreen` | `false` | Show fullscreen button |
439
- | `magnifier` | `data-magnifier` | `null` | Magnifier zoom level (1-5) |
440
- | `pointerZoom` | `data-pointer-zoom` | `0` | Pointer zoom level on click (1-5) |
438
+ | `zoomMax` | `data-zoom-max` | `5` | Maximum zoom level (1-10) |
439
+ | `zoomStep` | `data-zoom-step` | `0.5` | Zoom increment per step |
440
+ | `zoomControls` | `data-zoom-controls` | `true` | Show zoom control buttons (zoom in, zoom out, reset) |
441
+ | `zoomControlsPosition` | `data-zoom-controls-position` | `'bottom-right'` | Position of zoom controls toolbar. Values: `'top-left'`, `'top-center'`, `'top-right'`, `'bottom-left'`, `'bottom-center'`, `'bottom-right'` |
442
+ | `scrollHint` | `data-scroll-hint` | `true` | Show "Ctrl + scroll to zoom" hint on scroll |
441
443
  | `bottomCircle` | `data-bottom-circle` | `true` | Show 360° progress indicator |
442
444
  | `bottomCircleOffset` | `data-bottom-circle-offset` | `5` | Progress indicator offset (px) |
443
445
  | `initialIconShown` | `data-initial-icon` | `true` | Show 360° icon on load |
@@ -659,7 +661,7 @@ const config = {
659
661
  hints: false,
660
662
 
661
663
  // Custom hints array
662
- hints: ['drag', 'click', 'keys'],
664
+ hints: ['drag', 'dblclick', 'keys'],
663
665
  };
664
666
  ```
665
667
 
@@ -669,7 +671,7 @@ const config = {
669
671
  |------|---------|--------|-------------|
670
672
  | `drag` | ✓ | - | "Drag to rotate" |
671
673
  | `swipe` | - | ✓ | "Swipe to rotate" |
672
- | `click` | ✓ | - | "Click to zoom" (when pointerZoom enabled) |
674
+ | `dblclick` | ✓ | - | "Double-click to zoom" |
673
675
  | `pinch` | - | ✓ | "Pinch to zoom" (when pinchZoom enabled) |
674
676
  | `keys` | ✓ | - | "Use arrow keys" (when keys enabled) |
675
677
 
@@ -724,10 +726,18 @@ The easiest way to customize the viewer appearance:
724
726
  /* Fullscreen */
725
727
  --ci360-fullscreen-bg: #fff;
726
728
 
727
- /* Magnifier */
728
- --ci360-magnifier-size: 250px;
729
- --ci360-magnifier-border: 2px solid rgba(0, 0, 0, 0.3);
730
- --ci360-magnifier-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
729
+ /* Zoom Controls */
730
+ --ci360-zoom-controls-bg: rgba(255, 255, 255, 0.9);
731
+ --ci360-zoom-controls-bg-hover: rgba(255, 255, 255, 1);
732
+ --ci360-zoom-controls-color: #505050;
733
+ --ci360-zoom-controls-color-hover: #333333;
734
+ --ci360-zoom-controls-border-radius: 8px;
735
+ --ci360-zoom-controls-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
736
+
737
+ /* Scroll Hint */
738
+ --ci360-scroll-hint-bg: rgba(0, 0, 0, 0.7);
739
+ --ci360-scroll-hint-color: #ffffff;
740
+ --ci360-scroll-hint-border-radius: 20px;
731
741
 
732
742
  /* Hotspots */
733
743
  --ci360-hotspot-color: #00aaff;
@@ -802,7 +812,7 @@ If you prefer to customize beyond the built-in dark theme:
802
812
  | `.cloudimage-360-view-360-circle` | Bottom progress indicator |
803
813
  | `.cloudimage-loading-spinner` | Loading spinner |
804
814
  | `.cloudimage-360-fullscreen-modal` | Fullscreen container |
805
- | `.cloudimage-360-img-magnifier-glass` | Magnifier element |
815
+ | `.cloudimage-360-zoom-controls` | Zoom controls toolbar |
806
816
  | `.cloudimage-360-hotspot` | Hotspot marker |
807
817
  | `.cloudimage-360-popper` | Hotspot tooltip |
808
818
  | `.cloudimage-360-hints-overlay` | Hints overlay container |
@@ -933,8 +943,7 @@ Mobile browsers (especially Safari) have strict memory limits that can cause tab
933
943
  | Setting | Desktop | Mobile | Notes |
934
944
  |---------|---------|--------|-------|
935
945
  | `amountX` | 60-100+ | 30-40 max | Each image uses ~4MB GPU memory |
936
- | `pointerZoom` | | | Loads higher-res images |
937
- | `magnifier` | ✅ | ❌ | Loads higher-res images |
946
+ | `zoomMax` | `3-5` | `2-3` | Higher zoom loads more pixels |
938
947
 
939
948
  ### Detecting Mobile Devices
940
949
 
@@ -950,8 +959,7 @@ viewer.init(container, {
950
959
  folder: 'https://example.com/images/',
951
960
  filenameX: '{index}.jpg',
952
961
  amountX: isMobile ? 36 : 72, // Fewer images on mobile
953
- pointerZoom: isMobile ? false : 2, // Disable zoom on mobile
954
- magnifier: isMobile ? false : 3, // Disable magnifier on mobile
962
+ zoomMax: isMobile ? 2 : 5, // Lower zoom on mobile
955
963
  });
956
964
  ```
957
965
 
@@ -1126,7 +1134,7 @@ const config = {
1126
1134
  const config = {
1127
1135
  hints: true, // Auto-detect hints
1128
1136
  // or
1129
- hints: ['drag', 'click', 'keys'], // Custom hints
1137
+ hints: ['drag', 'dblclick', 'keys'], // Custom hints
1130
1138
  };
1131
1139
  ```
1132
1140