@opentiny/vue-renderless 3.11.4 → 3.11.5
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/image-viewer/index.js +2 -2
- package/image-viewer/vue.js +1 -1
- package/package.json +1 -1
package/image-viewer/index.js
CHANGED
|
@@ -321,7 +321,7 @@ const handleVisible = ({ state, emit, props }) => () => {
|
|
|
321
321
|
state.transform.scale = 1;
|
|
322
322
|
state.transform.deg = 0;
|
|
323
323
|
setTimeout(() => {
|
|
324
|
-
if (props.startPosition
|
|
324
|
+
if (props.startPosition > 0) {
|
|
325
325
|
state.index = (props.startPosition - 1 + state.urlList.length) % state.urlList.length;
|
|
326
326
|
state.imageTransform = state.index * state.imageItemWidth;
|
|
327
327
|
state.imageTransformSize = -state.index * state.imageItemWidth;
|
|
@@ -354,7 +354,7 @@ const getImageWidth = ({ state, parent, props, vm, mode }) => () => {
|
|
|
354
354
|
state.imageItemWidth = imageW;
|
|
355
355
|
state.imageAllWidth = state.urlList.length * imageW;
|
|
356
356
|
if (mode !== "mobile-first") {
|
|
357
|
-
if (props.startPosition
|
|
357
|
+
if (props.startPosition > 0) {
|
|
358
358
|
state.index = props.startPosition;
|
|
359
359
|
state.imageTransition = 0;
|
|
360
360
|
const transformX = state.index * state.imageItemWidth;
|
package/image-viewer/vue.js
CHANGED
|
@@ -78,7 +78,7 @@ const initState = ({ reactive, computed, api: api2, mode, props, constants, inje
|
|
|
78
78
|
infinite: true,
|
|
79
79
|
loading: false,
|
|
80
80
|
transform: { scale: 1, deg: 0, offsetX: 0, offsetY: 0, objfit: "contain", enableTransition: false },
|
|
81
|
-
urlList: inject("urlList", null)
|
|
81
|
+
urlList: props.urlList || inject("urlList", null),
|
|
82
82
|
mode: constants.MODE.CONTAIN,
|
|
83
83
|
previewVisible: props.previewVisible,
|
|
84
84
|
fullScreen: props.imageFullCurrent,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opentiny/vue-renderless",
|
|
3
|
-
"version": "3.11.
|
|
3
|
+
"version": "3.11.5",
|
|
4
4
|
"description": "An enterprise-class UI component library, support both Vue.js 2 and Vue.js 3, as well as PC and mobile.",
|
|
5
5
|
"homepage": "https://opentiny.design/tiny-vue",
|
|
6
6
|
"keywords": [
|