@varlet/ui 2.13.1-alpha.1689619056304 → 2.13.1
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/es/action-sheet/index.mjs +3 -7
- package/es/app-bar/index.mjs +2 -3
- package/es/avatar/index.mjs +2 -3
- package/es/avatar-group/index.mjs +2 -3
- package/es/back-top/index.mjs +2 -3
- package/es/badge/index.mjs +2 -3
- package/es/bottom-navigation/index.mjs +2 -3
- package/es/bottom-navigation-item/index.mjs +2 -3
- package/es/breadcrumb/index.mjs +2 -3
- package/es/breadcrumbs/index.mjs +2 -3
- package/es/button/index.mjs +2 -3
- package/es/button-group/index.mjs +2 -4
- package/es/card/index.mjs +2 -3
- package/es/cell/index.mjs +2 -3
- package/es/checkbox/index.mjs +2 -3
- package/es/checkbox-group/index.mjs +2 -3
- package/es/chip/index.mjs +2 -3
- package/es/col/index.mjs +2 -3
- package/es/collapse/index.mjs +2 -3
- package/es/collapse-item/index.mjs +2 -3
- package/es/countdown/index.mjs +2 -3
- package/es/counter/index.mjs +2 -3
- package/es/date-picker/index.mjs +2 -3
- package/es/dialog/index.mjs +3 -7
- package/es/divider/index.mjs +2 -3
- package/es/drag/index.mjs +2 -3
- package/es/ellipsis/index.mjs +2 -3
- package/es/fab/index.mjs +2 -4
- package/es/form/index.mjs +2 -4
- package/es/form-details/index.mjs +2 -3
- package/es/hover-overlay/index.mjs +2 -3
- package/es/icon/index.mjs +2 -3
- package/es/image/index.mjs +2 -3
- package/es/image-preview/index.mjs +3 -7
- package/es/index-anchor/index.mjs +2 -3
- package/es/index-bar/index.mjs +2 -3
- package/es/index.bundle.mjs +1 -1
- package/es/index.mjs +1 -1
- package/es/input/index.mjs +2 -3
- package/es/link/index.mjs +2 -3
- package/es/list/index.mjs +2 -3
- package/es/loading/index.mjs +2 -3
- package/es/menu/Menu.mjs +3 -1
- package/es/menu/index.mjs +2 -3
- package/es/menu/menu.css +1 -1
- package/es/menu/usePopover.mjs +52 -1
- package/es/option/index.mjs +2 -3
- package/es/overlay/index.mjs +2 -3
- package/es/pagination/index.mjs +2 -3
- package/es/paper/index.mjs +2 -3
- package/es/picker/index.mjs +4 -8
- package/es/popup/index.mjs +2 -3
- package/es/progress/index.mjs +2 -3
- package/es/pull-refresh/index.mjs +2 -3
- package/es/radio/index.mjs +2 -3
- package/es/radio-group/index.mjs +2 -3
- package/es/rate/index.mjs +2 -3
- package/es/result/index.mjs +2 -3
- package/es/row/index.mjs +2 -3
- package/es/select/Select.mjs +1 -1
- package/es/select/index.mjs +2 -3
- package/es/skeleton/index.mjs +2 -3
- package/es/slider/index.mjs +2 -3
- package/es/snackbar/index.mjs +4 -8
- package/es/space/index.mjs +2 -3
- package/es/step/index.mjs +2 -3
- package/es/steps/index.mjs +2 -3
- package/es/sticky/index.mjs +2 -3
- package/es/style-provider/index.mjs +3 -6
- package/es/style.css +1 -1
- package/es/swipe/index.mjs +2 -3
- package/es/swipe-item/index.mjs +2 -3
- package/es/switch/index.mjs +2 -3
- package/es/tab/index.mjs +2 -3
- package/es/tab-item/index.mjs +2 -3
- package/es/table/index.mjs +2 -3
- package/es/tabs/index.mjs +2 -3
- package/es/tabs-items/index.mjs +2 -3
- package/es/time-picker/index.mjs +2 -3
- package/es/tooltip/Tooltip.mjs +3 -1
- package/es/tooltip/index.mjs +2 -3
- package/es/tooltip/tooltip.css +1 -1
- package/es/uploader/index.mjs +2 -3
- package/es/utils/components.mjs +12 -0
- package/es/varlet.esm.js +7052 -7151
- package/highlight/web-types.en-US.json +2 -2
- package/highlight/web-types.zh-CN.json +3 -3
- package/lib/style.css +1 -1
- package/lib/varlet.cjs.js +154 -247
- package/package.json +6 -6
- package/types/snackbar.d.ts +9 -10
- package/umd/varlet.js +5 -5
|
@@ -2,7 +2,7 @@ function _extends() { _extends = Object.assign ? Object.assign.bind() : function
|
|
|
2
2
|
import VarActionSheet from './ActionSheet.mjs';
|
|
3
3
|
import { nextTick, reactive } from 'vue';
|
|
4
4
|
import { inBrowser } from '@varlet/shared';
|
|
5
|
-
import { call, mountInstance } from '../utils/components.mjs';
|
|
5
|
+
import { call, mountInstance, withInstall } from '../utils/components.mjs';
|
|
6
6
|
var singletonOptions;
|
|
7
7
|
var defaultOptions = {};
|
|
8
8
|
function normalizeOptions(options) {
|
|
@@ -63,12 +63,8 @@ ActionSheet.close = function () {
|
|
|
63
63
|
}
|
|
64
64
|
};
|
|
65
65
|
ActionSheet.Component = VarActionSheet;
|
|
66
|
-
VarActionSheet
|
|
67
|
-
|
|
68
|
-
};
|
|
69
|
-
ActionSheet.install = function (app) {
|
|
70
|
-
app.component(VarActionSheet.name, VarActionSheet);
|
|
71
|
-
};
|
|
66
|
+
withInstall(VarActionSheet);
|
|
67
|
+
withInstall(VarActionSheet, ActionSheet);
|
|
72
68
|
export { props as actionSheetProps } from './props.mjs';
|
|
73
69
|
export var _ActionSheetComponent = VarActionSheet;
|
|
74
70
|
export default ActionSheet;
|
package/es/app-bar/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import AppBar from './AppBar.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(AppBar);
|
|
5
4
|
export { props as appBarProps } from './props.mjs';
|
|
6
5
|
export var _AppBarComponent = AppBar;
|
|
7
6
|
export default AppBar;
|
package/es/avatar/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Avatar from './Avatar.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Avatar);
|
|
5
4
|
export { props as avatarProps } from './props.mjs';
|
|
6
5
|
export var _AvatarComponent = Avatar;
|
|
7
6
|
export default Avatar;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import AvatarGroup from './AvatarGroup.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(AvatarGroup);
|
|
5
4
|
export { props as avatarGroupProps } from './props.mjs';
|
|
6
5
|
export var _AvatarGroupComponent = AvatarGroup;
|
|
7
6
|
export default AvatarGroup;
|
package/es/back-top/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import BackTop from './BackTop.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(BackTop);
|
|
5
4
|
export { props as backTopProps } from './props.mjs';
|
|
6
5
|
export var _BackTopComponent = BackTop;
|
|
7
6
|
export default BackTop;
|
package/es/badge/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Badge from './Badge.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Badge);
|
|
5
4
|
export { props as badgeProps } from './props.mjs';
|
|
6
5
|
export var _BadgeComponent = Badge;
|
|
7
6
|
export default Badge;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import BottomNavigation from './BottomNavigation.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(BottomNavigation);
|
|
5
4
|
export { props as bottomNavigationProps } from './props.mjs';
|
|
6
5
|
export var _BottomNavigationComponent = BottomNavigation;
|
|
7
6
|
export default BottomNavigation;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import BottomNavigationItem from './BottomNavigationItem.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(BottomNavigationItem);
|
|
5
4
|
export { props as bottomNavigationItemProps } from './props.mjs';
|
|
6
5
|
export var _BottomNavigationItemComponent = BottomNavigationItem;
|
|
7
6
|
export default BottomNavigationItem;
|
package/es/breadcrumb/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Breadcrumb from './Breadcrumb.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Breadcrumb);
|
|
5
4
|
export { props as breadcrumbProps } from './props.mjs';
|
|
6
5
|
export var _BreadcrumbComponent = Breadcrumb;
|
|
7
6
|
export default Breadcrumb;
|
package/es/breadcrumbs/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Breadcrumbs from './Breadcrumbs.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Breadcrumbs);
|
|
5
4
|
export { props as breadcrumbsProps } from './props.mjs';
|
|
6
5
|
export var _BreadcrumbsComponent = Breadcrumbs;
|
|
7
6
|
export default Breadcrumbs;
|
package/es/button/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Button from './Button.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Button);
|
|
5
4
|
export { props as buttonProps } from './props.mjs';
|
|
6
5
|
export var _ButtonComponent = Button;
|
|
7
6
|
export default Button;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
// Component entry, the folder where the file exists will be exposed to the user
|
|
2
1
|
import ButtonGroup from './ButtonGroup.mjs';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(ButtonGroup);
|
|
6
4
|
export var _ButtonGroupComponent = ButtonGroup;
|
|
7
5
|
export default ButtonGroup;
|
package/es/card/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Card from './Card.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Card);
|
|
5
4
|
export { props as cardProps } from './props.mjs';
|
|
6
5
|
export var _CardComponent = Card;
|
|
7
6
|
export default Card;
|
package/es/cell/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Cell from './Cell.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Cell);
|
|
5
4
|
export { props as cellProps } from './props.mjs';
|
|
6
5
|
export var _CellComponent = Cell;
|
|
7
6
|
export default Cell;
|
package/es/checkbox/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Checkbox from './Checkbox.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Checkbox);
|
|
5
4
|
export { props as checkboxProps } from './props.mjs';
|
|
6
5
|
export var _CheckboxComponent = Checkbox;
|
|
7
6
|
export default Checkbox;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import CheckboxGroup from './CheckboxGroup.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(CheckboxGroup);
|
|
5
4
|
export { props as checkboxGroupProps } from './props.mjs';
|
|
6
5
|
export var _CheckboxGroupComponent = CheckboxGroup;
|
|
7
6
|
export default CheckboxGroup;
|
package/es/chip/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Chip from './Chip.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Chip);
|
|
5
4
|
export { props as chipProps } from './props.mjs';
|
|
6
5
|
export var _ChipComponent = Chip;
|
|
7
6
|
export default Chip;
|
package/es/col/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Col from './Col.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Col);
|
|
5
4
|
export { props as colProps } from './props.mjs';
|
|
6
5
|
export var _ColComponent = Col;
|
|
7
6
|
export default Col;
|
package/es/collapse/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Collapse from './Collapse.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Collapse);
|
|
5
4
|
export { props as collapseProps } from './props.mjs';
|
|
6
5
|
export var _CollapseComponent = Collapse;
|
|
7
6
|
export default Collapse;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import CollapseItem from './CollapseItem.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(CollapseItem);
|
|
5
4
|
export { props as collapseItemProps } from './props.mjs';
|
|
6
5
|
export var _CollapseItemComponent = CollapseItem;
|
|
7
6
|
export default CollapseItem;
|
package/es/countdown/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Countdown from './Countdown.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Countdown);
|
|
5
4
|
export { props as countdownProps } from './props.mjs';
|
|
6
5
|
export var _CountdownComponent = Countdown;
|
|
7
6
|
export default Countdown;
|
package/es/counter/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Counter from './Counter.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Counter);
|
|
5
4
|
export { props as counterProps } from './props.mjs';
|
|
6
5
|
export var _CounterComponent = Counter;
|
|
7
6
|
export default Counter;
|
package/es/date-picker/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import DatePicker from './DatePicker.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(DatePicker);
|
|
5
4
|
export { props as datePickerProps } from './props.mjs';
|
|
6
5
|
export var _DatePickerComponent = DatePicker;
|
|
7
6
|
export default DatePicker;
|
package/es/dialog/index.mjs
CHANGED
|
@@ -2,7 +2,7 @@ function _extends() { _extends = Object.assign ? Object.assign.bind() : function
|
|
|
2
2
|
import VarDialog from './Dialog.mjs';
|
|
3
3
|
import { reactive, nextTick } from 'vue';
|
|
4
4
|
import { inBrowser, isString } from '@varlet/shared';
|
|
5
|
-
import { call, mountInstance } from '../utils/components.mjs';
|
|
5
|
+
import { call, mountInstance, withInstall } from '../utils/components.mjs';
|
|
6
6
|
var singletonOptions;
|
|
7
7
|
var defaultOptions = {};
|
|
8
8
|
function normalizeOptions(options) {
|
|
@@ -72,13 +72,9 @@ Dialog.close = function () {
|
|
|
72
72
|
});
|
|
73
73
|
}
|
|
74
74
|
};
|
|
75
|
-
VarDialog.install = function (app) {
|
|
76
|
-
app.component(VarDialog.name, VarDialog);
|
|
77
|
-
};
|
|
78
|
-
Dialog.install = function (app) {
|
|
79
|
-
app.component(VarDialog.name, VarDialog);
|
|
80
|
-
};
|
|
81
75
|
Dialog.Component = VarDialog;
|
|
76
|
+
withInstall(VarDialog);
|
|
77
|
+
withInstall(VarDialog, Dialog);
|
|
82
78
|
export { props as dialogProps } from './props.mjs';
|
|
83
79
|
export var _DialogComponent = VarDialog;
|
|
84
80
|
export default Dialog;
|
package/es/divider/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Divider from './Divider.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Divider);
|
|
5
4
|
export { props as dividerProps } from './props.mjs';
|
|
6
5
|
export var _DividerComponent = Divider;
|
|
7
6
|
export default Divider;
|
package/es/drag/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Drag from './Drag.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Drag);
|
|
5
4
|
export { props as dragProps } from './props.mjs';
|
|
6
5
|
export var _DragComponent = Drag;
|
|
7
6
|
export default Drag;
|
package/es/ellipsis/index.mjs
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import Ellipsis from './Ellipsis.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Ellipsis);
|
|
5
4
|
export var _EllipsisComponent = Ellipsis;
|
|
6
5
|
export default Ellipsis;
|
package/es/fab/index.mjs
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
// Component entry, the folder where the file exists will be exposed to the user
|
|
2
1
|
import Fab from './Fab.mjs';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Fab);
|
|
6
4
|
export var _FabComponent = Fab;
|
|
7
5
|
export default Fab;
|
package/es/form/index.mjs
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import Form from './Form.mjs';
|
|
2
|
-
import { useValidation } from '../utils/components.mjs';
|
|
2
|
+
import { useValidation, withInstall } from '../utils/components.mjs';
|
|
3
3
|
import { useForm } from './provide.mjs';
|
|
4
|
-
Form.install = function (app) {
|
|
5
|
-
app.component(Form.name, Form);
|
|
6
|
-
};
|
|
7
4
|
Form.useValidation = useValidation;
|
|
8
5
|
Form.useForm = useForm;
|
|
6
|
+
withInstall(Form);
|
|
9
7
|
export { props as formProps } from './props.mjs';
|
|
10
8
|
export var _FormComponent = Form;
|
|
11
9
|
export default Form;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import FormDetails from './FormDetails.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(FormDetails);
|
|
5
4
|
export { props as formDetailsProps } from './props.mjs';
|
|
6
5
|
export var _FormDetailsComponent = FormDetails;
|
|
7
6
|
export default FormDetails;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import HoverOverlay from './HoverOverlay.mjs';
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
2
3
|
import { ref } from 'vue';
|
|
3
|
-
HoverOverlay
|
|
4
|
-
app.component(HoverOverlay.name, HoverOverlay);
|
|
5
|
-
};
|
|
4
|
+
withInstall(HoverOverlay);
|
|
6
5
|
export function useHoverOverlay() {
|
|
7
6
|
var hovering = ref(false);
|
|
8
7
|
var handleHovering = value => {
|
package/es/icon/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Icon from './Icon.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Icon);
|
|
5
4
|
export { props as iconProps } from './props.mjs';
|
|
6
5
|
export var _IconComponent = Icon;
|
|
7
6
|
export default Icon;
|
package/es/image/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Image from './Image.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Image);
|
|
5
4
|
export { props as imageProps } from './props.mjs';
|
|
6
5
|
export var _ImageComponent = Image;
|
|
7
6
|
export default Image;
|
|
@@ -2,7 +2,7 @@ function _extends() { _extends = Object.assign ? Object.assign.bind() : function
|
|
|
2
2
|
import VarImagePreview from './ImagePreview.mjs';
|
|
3
3
|
import { nextTick, reactive } from 'vue';
|
|
4
4
|
import { inBrowser, isArray, isString } from '@varlet/shared';
|
|
5
|
-
import { call, mountInstance } from '../utils/components.mjs';
|
|
5
|
+
import { call, mountInstance, withInstall } from '../utils/components.mjs';
|
|
6
6
|
var singletonOptions;
|
|
7
7
|
var defaultOptions = {};
|
|
8
8
|
function normalizeOptions(options) {
|
|
@@ -64,13 +64,9 @@ ImagePreview.setDefaultOptions = options => {
|
|
|
64
64
|
ImagePreview.resetDefaultOptions = () => {
|
|
65
65
|
defaultOptions = {};
|
|
66
66
|
};
|
|
67
|
-
VarImagePreview.install = function (app) {
|
|
68
|
-
app.component(VarImagePreview.name, VarImagePreview);
|
|
69
|
-
};
|
|
70
|
-
ImagePreview.install = function (app) {
|
|
71
|
-
app.component(VarImagePreview.name, VarImagePreview);
|
|
72
|
-
};
|
|
73
67
|
ImagePreview.Component = VarImagePreview;
|
|
68
|
+
withInstall(VarImagePreview);
|
|
69
|
+
withInstall(VarImagePreview, ImagePreview);
|
|
74
70
|
export { props as imagePreviewProps } from './props.mjs';
|
|
75
71
|
export var _ImagePreviewComponent = VarImagePreview;
|
|
76
72
|
export default ImagePreview;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import IndexAnchor from './IndexAnchor.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(IndexAnchor);
|
|
5
4
|
export { props as indexAnchorProps } from './props.mjs';
|
|
6
5
|
export var _IndexAnchorComponent = IndexAnchor;
|
|
7
6
|
export default IndexAnchor;
|
package/es/index-bar/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import IndexBar from './IndexBar.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(IndexBar);
|
|
5
4
|
export { props as indexBarProps } from './props.mjs';
|
|
6
5
|
export var _IndexBarComponent = IndexBar;
|
|
7
6
|
export default IndexBar;
|
package/es/index.bundle.mjs
CHANGED
|
@@ -244,7 +244,7 @@ import './time-picker/style/index.mjs'
|
|
|
244
244
|
import './tooltip/style/index.mjs'
|
|
245
245
|
import './uploader/style/index.mjs'
|
|
246
246
|
|
|
247
|
-
const version = '2.13.1
|
|
247
|
+
const version = '2.13.1'
|
|
248
248
|
|
|
249
249
|
function install(app) {
|
|
250
250
|
ActionSheet.install && app.use(ActionSheet)
|
package/es/index.mjs
CHANGED
|
@@ -162,7 +162,7 @@ export * from './time-picker/index.mjs'
|
|
|
162
162
|
export * from './tooltip/index.mjs'
|
|
163
163
|
export * from './uploader/index.mjs'
|
|
164
164
|
|
|
165
|
-
const version = '2.13.1
|
|
165
|
+
const version = '2.13.1'
|
|
166
166
|
|
|
167
167
|
function install(app) {
|
|
168
168
|
ActionSheet.install && app.use(ActionSheet)
|
package/es/input/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Input from './Input.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Input);
|
|
5
4
|
export { props as inputProps } from './props.mjs';
|
|
6
5
|
export var _InputComponent = Input;
|
|
7
6
|
export default Input;
|
package/es/link/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Link from './Link.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Link);
|
|
5
4
|
export { props as linkProps } from './props.mjs';
|
|
6
5
|
export var _LinkComponent = Link;
|
|
7
6
|
export default Link;
|
package/es/list/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import List from './List.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(List);
|
|
5
4
|
export { props as listProps } from './props.mjs';
|
|
6
5
|
export var _ListComponent = List;
|
|
7
6
|
export default List;
|
package/es/loading/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Loading from './Loading.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Loading);
|
|
5
4
|
export { props as loadingProps } from './props.mjs';
|
|
6
5
|
export var _LoadingComponent = Loading;
|
|
7
6
|
export default Loading;
|
package/es/menu/Menu.mjs
CHANGED
|
@@ -26,7 +26,7 @@ function __render__(_ctx, _cache) {
|
|
|
26
26
|
}, [_createVNode(_Transition, {
|
|
27
27
|
name: _ctx.n(),
|
|
28
28
|
onAfterEnter: _ctx.onOpened,
|
|
29
|
-
onAfterLeave: _ctx.
|
|
29
|
+
onAfterLeave: _ctx.handleClosed,
|
|
30
30
|
persisted: ""
|
|
31
31
|
}, {
|
|
32
32
|
default: _withCtx(() => [_withDirectives(_createElementVNode("div", {
|
|
@@ -64,6 +64,7 @@ var __sfc__ = defineComponent({
|
|
|
64
64
|
handlePopoverMouseenter,
|
|
65
65
|
handlePopoverMouseleave,
|
|
66
66
|
handlePopoverClose,
|
|
67
|
+
handleClosed,
|
|
67
68
|
// expose
|
|
68
69
|
open,
|
|
69
70
|
// expose
|
|
@@ -87,6 +88,7 @@ var __sfc__ = defineComponent({
|
|
|
87
88
|
handlePopoverMouseenter,
|
|
88
89
|
handlePopoverMouseleave,
|
|
89
90
|
handlePopoverClose,
|
|
91
|
+
handleClosed,
|
|
90
92
|
resize,
|
|
91
93
|
open,
|
|
92
94
|
close
|
package/es/menu/index.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Menu from './Menu.mjs';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
2
|
+
import { withInstall } from '../utils/components.mjs';
|
|
3
|
+
withInstall(Menu);
|
|
5
4
|
export { props as menuProps } from './props.mjs';
|
|
6
5
|
export var _MenuComponent = Menu;
|
|
7
6
|
export default Menu;
|
package/es/menu/menu.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
:root { --menu-background-color: #fff;}.var-menu-enter-from,.var-menu-leave-to { opacity: 0;}.var-menu-enter-active,.var-menu-leave-active { transition-property: opacity; transition-duration: 0.
|
|
1
|
+
:root { --menu-background-color: #fff;}.var-menu { display: inline-block;}.var-menu-enter-from,.var-menu-leave-to { opacity: 0; transform: scale(0.8);}.var-menu-enter-active,.var-menu-leave-active { transition-property: opacity, transform; transition-duration: 0.2s;}.var-menu--menu-background-color { background: var(--menu-background-color);}
|
package/es/menu/usePopover.mjs
CHANGED
|
@@ -45,6 +45,38 @@ export function usePopover(options) {
|
|
|
45
45
|
height: toPxNum(height)
|
|
46
46
|
};
|
|
47
47
|
};
|
|
48
|
+
var getTransformOrigin = () => {
|
|
49
|
+
switch (options.placement) {
|
|
50
|
+
case 'top':
|
|
51
|
+
case 'cover-bottom':
|
|
52
|
+
return 'bottom';
|
|
53
|
+
case 'top-start':
|
|
54
|
+
case 'right-end':
|
|
55
|
+
case 'cover-bottom-start':
|
|
56
|
+
return 'bottom left';
|
|
57
|
+
case 'top-end':
|
|
58
|
+
case 'left-end':
|
|
59
|
+
case 'cover-bottom-end':
|
|
60
|
+
return 'bottom right';
|
|
61
|
+
case 'bottom':
|
|
62
|
+
case 'cover-top':
|
|
63
|
+
return 'top';
|
|
64
|
+
case 'bottom-start':
|
|
65
|
+
case 'right-start':
|
|
66
|
+
case 'cover-top-start':
|
|
67
|
+
return 'top left';
|
|
68
|
+
case 'bottom-end':
|
|
69
|
+
case 'left-start':
|
|
70
|
+
case 'cover-top-end':
|
|
71
|
+
return 'top right';
|
|
72
|
+
case 'left':
|
|
73
|
+
case 'cover-right':
|
|
74
|
+
return 'right';
|
|
75
|
+
case 'right':
|
|
76
|
+
case 'cover-left':
|
|
77
|
+
return 'left';
|
|
78
|
+
}
|
|
79
|
+
};
|
|
48
80
|
var handleHostMouseenter = () => {
|
|
49
81
|
if (options.trigger !== 'hover') {
|
|
50
82
|
return;
|
|
@@ -107,6 +139,10 @@ export function usePopover(options) {
|
|
|
107
139
|
handlePopoverClose();
|
|
108
140
|
call(options.onClickOutside, e);
|
|
109
141
|
};
|
|
142
|
+
var handleClosed = () => {
|
|
143
|
+
resize();
|
|
144
|
+
call(options.onClosed);
|
|
145
|
+
};
|
|
110
146
|
var getPosition = () => {
|
|
111
147
|
computeHostSize();
|
|
112
148
|
var offset = {
|
|
@@ -209,8 +245,22 @@ export function usePopover(options) {
|
|
|
209
245
|
offset: [skidding, distance]
|
|
210
246
|
}
|
|
211
247
|
}), _extends({}, computeStyles, {
|
|
248
|
+
options: {
|
|
249
|
+
adaptive: false,
|
|
250
|
+
gpuAcceleration: false
|
|
251
|
+
},
|
|
212
252
|
enabled: show.value
|
|
213
|
-
})
|
|
253
|
+
}), {
|
|
254
|
+
name: 'applyTransformOrigin',
|
|
255
|
+
enabled: show.value,
|
|
256
|
+
phase: 'beforeWrite',
|
|
257
|
+
fn(_ref3) {
|
|
258
|
+
var {
|
|
259
|
+
state
|
|
260
|
+
} = _ref3;
|
|
261
|
+
state.styles.popper.transformOrigin = getTransformOrigin();
|
|
262
|
+
}
|
|
263
|
+
}];
|
|
214
264
|
return {
|
|
215
265
|
placement,
|
|
216
266
|
modifiers
|
|
@@ -264,6 +314,7 @@ export function usePopover(options) {
|
|
|
264
314
|
handlePopoverClose,
|
|
265
315
|
handlePopoverMouseenter,
|
|
266
316
|
handlePopoverMouseleave,
|
|
317
|
+
handleClosed,
|
|
267
318
|
resize,
|
|
268
319
|
open,
|
|
269
320
|
close
|