cosey 0.1.1 → 0.1.3
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/audio-card/audio-card.vue.js +1 -1
- package/components/close/close.vue.js +1 -1
- package/components/components.d.ts +98 -44
- package/components/config-provider/config-provider.js +1 -3
- package/components/config-provider/config-provider.vue.d.ts +2 -7
- package/components/config-provider/index.d.ts +1 -1
- package/components/context-menu/content.vue.js +1 -1
- package/components/context-menu/context-menu.vue.js +2 -2
- package/components/copy/copy.vue.js +1 -1
- package/components/cssinjs/parser.js +8 -25
- package/components/dnd-sort/dnd-sort-item.vue.js +2 -3
- package/components/dnd-sort/dnd-sort.vue.js +1 -2
- package/components/dnd-sort/index.d.ts +1 -1
- package/components/editor/components/button-group.vue.d.ts +2 -7
- package/components/editor/components/button.vue.d.ts +2 -7
- package/components/editor/components/color-picker/color-picker.vue.d.ts +2 -43
- package/components/editor/components/color-picker/color-picker.vue.js +14 -11
- package/components/editor/components/picker/picker.vue.d.ts +2 -15
- package/components/editor/components/resize/resize.js +4 -4
- package/components/editor/components/resize/resize.style.js +9 -32
- package/components/editor/components/resize/resize.vue.js +21 -14
- package/components/editor/components/select-button.vue.d.ts +2 -9
- package/components/editor/components/select-button.vue.js +1 -1
- package/components/editor/components/split-button.vue.d.ts +2 -19
- package/components/editor/components/split-button.vue.js +1 -1
- package/components/editor/components/table-toolbar/table-toolbar.vue.js +9 -9
- package/components/editor/components/toolbar/formats/align.vue.js +4 -4
- package/components/editor/components/toolbar/formats/blockquote.vue.js +1 -1
- package/components/editor/components/toolbar/formats/bold.vue.js +1 -1
- package/components/editor/components/toolbar/formats/clean.vue.js +1 -1
- package/components/editor/components/toolbar/formats/code-block.vue.js +1 -1
- package/components/editor/components/toolbar/formats/code.vue.js +1 -1
- package/components/editor/components/toolbar/formats/formula.vue.js +4 -3
- package/components/editor/components/toolbar/formats/image.vue.js +1 -1
- package/components/editor/components/toolbar/formats/indent.vue.js +2 -2
- package/components/editor/components/toolbar/formats/italic.vue.js +1 -1
- package/components/editor/components/toolbar/formats/link.vue.js +15 -13
- package/components/editor/components/toolbar/formats/list.vue.js +3 -3
- package/components/editor/components/toolbar/formats/script.vue.js +2 -2
- package/components/editor/components/toolbar/formats/size-delta.vue.js +2 -2
- package/components/editor/components/toolbar/formats/strike.vue.js +1 -1
- package/components/editor/components/toolbar/formats/table.vue.js +1 -1
- package/components/editor/components/toolbar/formats/underline.vue.js +1 -1
- package/components/editor/components/toolbar/formats/video.vue.js +1 -1
- package/components/editor/components/toolbar/toolbar.d.ts +1 -2
- package/components/editor/components/toolbar/toolbar.js +17 -21
- package/components/editor/components/toolbar/toolbarContext.js +1 -3
- package/components/editor/formats/image.d.ts +13 -0
- package/components/editor/formats/image.js +46 -0
- package/components/editor/formats/indent.d.ts +2 -0
- package/components/editor/formats/indent.js +12 -7
- package/components/editor/formats/link.js +1 -5
- package/components/editor/formats/list.d.ts +0 -4
- package/components/editor/formats/list.js +10 -5
- package/components/editor/formats/video.js +6 -9
- package/components/editor/modules/custom-list.js +1 -6
- package/components/editor/modules/image-uploader/formats/image-loading.style.js +3 -3
- package/components/editor/modules/image-uploader/image-uploader.js +1 -3
- package/components/editor/quill.js +7 -4
- package/components/editor/quillContext.js +1 -3
- package/components/editor/style/index.js +1 -5
- package/components/field/components/checkbox-group/panel.vue.d.ts +2 -20
- package/components/field/components/checkbox-group/panel.vue.js +2 -2
- package/components/field/components/tree-select/tree-select.d.ts +1 -2
- package/components/field/components/tree-select/tree-select.js +69 -0
- package/components/file-card/file-card.vue.js +1 -1
- package/components/form/form-item.vue.js +1 -1
- package/components/form/useFormItemWidth.js +1 -1
- package/components/form/useFormTemplate.js +2 -10
- package/components/form-dialog/form-dialog.vue.d.ts +0 -1
- package/components/form-dialog/form-dialog.vue.js +1 -1
- package/components/form-dialog/index.d.ts +0 -3
- package/components/form-group/form-group.vue.js +1 -1
- package/components/form-list/form-list.js +1 -6
- package/components/form-list/form-list.vue.js +2 -2
- package/components/form-query/form-query.vue.js +5 -5
- package/components/horizontal-tree/horizontal-tree.vue.js +16 -12
- package/components/iconify-icon/iconify-icon.d.ts +3 -0
- package/components/iconify-icon/iconify-icon.js +9 -0
- package/components/iconify-icon/iconify-icon.vue.js +2 -5
- package/components/iconify-icon/index.js +1 -0
- package/components/index.js +3 -2
- package/components/media-card-group/media-card-group.vue.js +4 -3
- package/components/scroll-view/scroll-view.vue.js +1 -2
- package/components/snug-menu/snug-menu.vue.js +1 -2
- package/components/style/animation.d.ts +5 -0
- package/components/style/animation.js +33 -0
- package/components/style/index.d.ts +1 -1
- package/components/style/index.js +2 -2
- package/components/style/mixins.d.ts +2 -0
- package/components/style/mixins.js +10 -1
- package/components/table/index.d.ts +0 -8
- package/components/table/style/index.js +2 -2
- package/components/table/table-column/renderer.js +22 -18
- package/components/table/table-column-editor/item.vue.js +4 -7
- package/components/table/table-column-editor/table-column-editor.vue.d.ts +2 -246
- package/components/table/table-column-editor/table-column-editor.vue.js +9 -9
- package/components/table/table-export/table-export.vue.js +2 -2
- package/components/table/table-query/table-query.d.ts +0 -4
- package/components/table/table-query/table-query.js +0 -4
- package/components/table/table-query/table-query.vue.d.ts +0 -9
- package/components/table/table-query/table-query.vue.js +14 -12
- package/components/table/table.js +1 -3
- package/components/table/table.vue.js +22 -24
- package/components/table/useTable.js +1 -4
- package/components/table/utils.js +1 -3
- package/components/table-action/item.vue.js +5 -5
- package/components/table-action/table-action.vue.js +4 -3
- package/components/theme/StyleContext.js +1 -3
- package/components/theme/createCacheToken.js +1 -4
- package/components/theme/getGlobalStyleHook.js +2 -5
- package/components/theme/getSimpleStyleHook.js +1 -4
- package/components/theme/getStyleHook.js +1 -4
- package/components/theme/interface/index.d.ts +1 -1
- package/components/theme/themes/shared/genColorMapToken.js +1 -4
- package/components/theme/useStyleRegister.js +1 -3
- package/components/theme/util/alias.js +4 -16
- package/components/theme/util/getAlphaColor.js +1 -6
- package/components/theme/util/normalizeStyle.js +1 -1
- package/components/theme/util/statistic.js +4 -1
- package/components/theme/util/useToken.js +1 -4
- package/components/toggle/toggle.vue.js +1 -1
- package/components/transition/transition.vue.js +1 -2
- package/components/upload/upload-item.vue.js +8 -8
- package/components/upload/upload.vue.js +1 -1
- package/components/video-card/video-card.vue.js +1 -1
- package/config/index.d.ts +1 -0
- package/config/index.js +2 -7
- package/config/layout.d.ts +36 -0
- package/config/layout.js +37 -1
- package/config/nprogress.style.d.ts +2 -0
- package/config/nprogress.style.js +51 -0
- package/config/root-config-provider.vue.d.ts +2 -20
- package/config/root-config-provider.vue.js +2 -0
- package/hooks/useColorScheme.js +5 -9
- package/hooks/useEcharts.js +2 -4
- package/hooks/useFetch.d.ts +1 -1
- package/hooks/useFetch.js +1 -7
- package/hooks/useFullPage.js +7 -9
- package/hooks/useLocale.js +1 -3
- package/hooks/useLockscreenObserver.js +1 -1
- package/hooks/usePersist.js +1 -3
- package/hooks/useTreeCheck.js +13 -26
- package/hooks/useUpsert.d.ts +3 -3
- package/index.d.ts +1 -0
- package/index.js +5 -4
- package/layout/index.js +2 -2
- package/layout/layout-aside/layout-aside.vue.js +2 -1
- package/layout/layout-base/layout-base.vue.js +1 -1
- package/layout/layout-change-password/layout-change-password.vue.js +8 -8
- package/layout/layout-change-password/style/index.js +1 -1
- package/layout/layout-color-scheme/layout-color-scheme.vue.js +8 -14
- package/layout/layout-color-scheme/style/index.d.ts +0 -3
- package/layout/layout-color-scheme/style/index.js +26 -44
- package/layout/layout-content/layout-content.vue.d.ts +2 -13
- package/layout/layout-forbidden/layout-forbidden.vue.js +2 -2
- package/layout/layout-header/layout-header.vue.d.ts +2 -14
- package/layout/layout-internal-server-error/layout-internal-server-error.vue.js +2 -2
- package/layout/layout-login/layout-login.vue.js +5 -5
- package/layout/layout-login/style/index.js +1 -1
- package/layout/layout-mask/style/index.js +1 -1
- package/layout/layout-not-found/layout-not-found.vue.js +2 -2
- package/layout/layout-search/layout-search.vue.js +37 -34
- package/layout/layout-sidebar/layout-sidebar.vue.d.ts +2 -15
- package/layout/layout-sidebar/style/index.js +1 -1
- package/layout/layout-switch-effect/layout-switch-effect.vue.d.ts +2 -7
- package/layout/layout-tabbar/layout-tabbar.vue.js +2 -2
- package/layout/layout-tabbar/reload.vue.js +1 -1
- package/layout/layout-tabbar/style/index.js +2 -2
- package/layout/layout-toggle/layout-toggle.vue.js +1 -1
- package/layout/layout-top-snug-menu/layout-top-snug-menu.vue.js +4 -3
- package/layout/layout-topbar/layout-topbar.vue.d.ts +2 -1217
- package/layout/layout-user-menu/index.d.ts +1 -0
- package/layout/layout-user-menu/index.js +1 -0
- package/layout/{layout-user/layout-user.vue.js → layout-user-menu/layout-user-menu.vue.js} +18 -13
- package/layout/{layout-user → layout-user-menu}/style/index.js +9 -5
- package/layout/layout.d.ts +1 -1
- package/layout/layout.js +1 -1
- package/layout/merged/index.d.ts +1 -1
- package/layout/merged/index.js +1 -1
- package/layout/merged/{layout-user.js → layout-user-menu.js} +1 -1
- package/layout/utils.js +1 -4
- package/package.json +16 -6
- package/request/useRequest.js +1 -1
- package/router/guard/auth.js +2 -5
- package/router/guard/index.js +0 -2
- package/router/guard/progress.js +11 -1
- package/router/index.d.ts +22 -0
- package/store/layout.d.ts +2 -8
- package/store/layout.js +19 -31
- package/store/user.d.ts +1 -1
- package/store/user.js +1 -1
- package/utils/array.js +3 -0
- package/utils/excel/index.js +1 -3
- package/utils/excel/utils.js +1 -5
- package/utils/file.js +1 -3
- package/utils/object.js +1 -3
- package/utils/tree.js +2 -11
- package/utils/vue.js +1 -1
- package/components/global.d.js +0 -1
- package/components/style/motion/index.d.ts +0 -1
- package/components/style/motion/index.js +0 -1
- package/components/style/motion/loading.d.ts +0 -3
- package/components/style/motion/loading.js +0 -23
- package/layout/layout-user/index.d.ts +0 -1
- package/layout/layout-user/index.js +0 -1
- package/router/guard/popup.d.ts +0 -2
- package/router/guard/popup.js +0 -6
- package/types/vue-router.d.js +0 -1
- package/types/vue.d.js +0 -1
- /package/layout/{layout-user/layout-user.vue.d.ts → layout-user-menu/layout-user-menu.vue.d.ts} +0 -0
- /package/layout/{layout-user → layout-user-menu}/style/index.d.ts +0 -0
- /package/layout/merged/{layout-user.d.ts → layout-user-menu.d.ts} +0 -0
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
import { Parchment } from 'quill';
|
|
2
2
|
|
|
3
|
+
const INDENT_STEP = 3;
|
|
3
4
|
class IndentAttributor extends Parchment.StyleAttributor {
|
|
5
|
+
normalize(value) {
|
|
6
|
+
if (!value) {
|
|
7
|
+
return void 0;
|
|
8
|
+
}
|
|
9
|
+
return Math.ceil(value / INDENT_STEP) * INDENT_STEP;
|
|
10
|
+
}
|
|
4
11
|
add(node, value) {
|
|
5
12
|
let normalizedValue = 0;
|
|
6
13
|
if (value === "+1" || value === "-1") {
|
|
7
14
|
const indent = this.value(node) || 0;
|
|
8
|
-
|
|
9
|
-
normalizedValue = value === "+1" ? indent + step : indent - step;
|
|
15
|
+
normalizedValue = value === "+1" ? indent + INDENT_STEP : indent - INDENT_STEP;
|
|
10
16
|
} else if (typeof value === "number") {
|
|
11
17
|
normalizedValue = value;
|
|
12
18
|
}
|
|
@@ -20,13 +26,12 @@ class IndentAttributor extends Parchment.StyleAttributor {
|
|
|
20
26
|
return super.canAdd(node, value) || super.canAdd(node, parseInt(value, 10));
|
|
21
27
|
}
|
|
22
28
|
value(node) {
|
|
23
|
-
return parseInt(super.value(node), 10)
|
|
29
|
+
return this.normalize(parseInt(super.value(node), 10));
|
|
24
30
|
}
|
|
25
31
|
}
|
|
26
|
-
const IndentStyle = new IndentAttributor("indent", "
|
|
32
|
+
const IndentStyle = new IndentAttributor("indent", "padding-left", {
|
|
27
33
|
scope: Parchment.Scope.BLOCK,
|
|
28
|
-
|
|
29
|
-
whitelist: Array(16).fill(0).map((_, i) => i + 1)
|
|
34
|
+
whitelist: Array(INDENT_STEP * 9).fill(0).map((_, i) => i + 1)
|
|
30
35
|
});
|
|
31
36
|
|
|
32
|
-
export { IndentStyle };
|
|
37
|
+
export { INDENT_STEP, IndentStyle };
|
|
@@ -31,11 +31,7 @@ class Link extends Inline {
|
|
|
31
31
|
this.toggleAttribute(domNode, "href", value.href);
|
|
32
32
|
this.toggleAttribute(domNode, "title", value.title);
|
|
33
33
|
this.toggleAttribute(domNode, "target", value.target);
|
|
34
|
-
this.toggleAttribute(
|
|
35
|
-
domNode,
|
|
36
|
-
"rel",
|
|
37
|
-
value.target === "_blank" ? "noopener noreferrer" : ""
|
|
38
|
-
);
|
|
34
|
+
this.toggleAttribute(domNode, "rel", value.target === "_blank" ? "noopener noreferrer" : "");
|
|
39
35
|
}
|
|
40
36
|
format(name, value) {
|
|
41
37
|
if (name !== this.statics.blotName || !value) {
|
|
@@ -2,12 +2,8 @@ import Block from 'quill/blots/block';
|
|
|
2
2
|
import Container from 'quill/blots/container';
|
|
3
3
|
import type Scroll from 'quill/blots/scroll';
|
|
4
4
|
declare class ListContainer extends Container {
|
|
5
|
-
static blotName: string;
|
|
6
|
-
static tagName: string;
|
|
7
5
|
}
|
|
8
6
|
declare class ListItem extends Block {
|
|
9
|
-
static blotName: string;
|
|
10
|
-
static tagName: string;
|
|
11
7
|
static create(value: string): HTMLElement;
|
|
12
8
|
static formats(domNode: HTMLElement): string | undefined;
|
|
13
9
|
static register(): void;
|
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
import Block from 'quill/blots/block';
|
|
2
2
|
import Container from 'quill/blots/container';
|
|
3
3
|
import Quill from 'quill/core/quill';
|
|
4
|
+
import { IndentStyle, INDENT_STEP } from './indent.js';
|
|
4
5
|
|
|
5
6
|
class ListContainer extends Container {
|
|
6
|
-
static blotName = "list-container";
|
|
7
|
-
static tagName = "OL";
|
|
8
7
|
}
|
|
8
|
+
ListContainer.blotName = "list-container";
|
|
9
|
+
ListContainer.tagName = "OL";
|
|
9
10
|
class ListItem extends Block {
|
|
10
|
-
static blotName = "list";
|
|
11
|
-
static tagName = "LI";
|
|
12
11
|
static create(value) {
|
|
13
12
|
const node = super.create();
|
|
14
13
|
node.setAttribute("data-list", value);
|
|
@@ -42,10 +41,16 @@ class ListItem extends Block {
|
|
|
42
41
|
if (name === this.statics.blotName && value) {
|
|
43
42
|
this.domNode.setAttribute("data-list", value);
|
|
44
43
|
} else {
|
|
45
|
-
|
|
44
|
+
if (name === IndentStyle.attrName) {
|
|
45
|
+
super.format(name, +value * INDENT_STEP);
|
|
46
|
+
} else {
|
|
47
|
+
super.format(name, value);
|
|
48
|
+
}
|
|
46
49
|
}
|
|
47
50
|
}
|
|
48
51
|
}
|
|
52
|
+
ListItem.blotName = "list";
|
|
53
|
+
ListItem.tagName = "LI";
|
|
49
54
|
ListContainer.allowedChildren = [ListItem];
|
|
50
55
|
ListItem.requiredContainer = ListContainer;
|
|
51
56
|
|
|
@@ -14,15 +14,12 @@ class Video extends BlockEmbed {
|
|
|
14
14
|
return node;
|
|
15
15
|
}
|
|
16
16
|
static formats(domNode) {
|
|
17
|
-
return ATTRIBUTES.reduce(
|
|
18
|
-
(
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
},
|
|
24
|
-
{}
|
|
25
|
-
);
|
|
17
|
+
return ATTRIBUTES.reduce((formats, attribute) => {
|
|
18
|
+
if (domNode.hasAttribute(attribute)) {
|
|
19
|
+
formats[attribute] = domNode.getAttribute(attribute);
|
|
20
|
+
}
|
|
21
|
+
return formats;
|
|
22
|
+
}, {});
|
|
26
23
|
}
|
|
27
24
|
static sanitize(url) {
|
|
28
25
|
return Link.sanitize(url);
|
|
@@ -13,12 +13,7 @@ class CustomList extends Module {
|
|
|
13
13
|
if (context.format.indent) {
|
|
14
14
|
formats.indent = false;
|
|
15
15
|
}
|
|
16
|
-
this.quill.formatLine(
|
|
17
|
-
range.index,
|
|
18
|
-
range.length,
|
|
19
|
-
formats,
|
|
20
|
-
Quill.sources.USER
|
|
21
|
-
);
|
|
16
|
+
this.quill.formatLine(range.index, range.length, formats, Quill.sources.USER);
|
|
22
17
|
}
|
|
23
18
|
});
|
|
24
19
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { getGlobalStyleHook } from '../../../../theme/getGlobalStyleHook.js';
|
|
2
|
-
import {
|
|
2
|
+
import { spinner, contrarotation } from '../../../../style/animation.js';
|
|
3
3
|
|
|
4
4
|
var stdin_default = getGlobalStyleHook("co-editor-image-loading", (token) => {
|
|
5
5
|
return {
|
|
@@ -22,12 +22,12 @@ var stdin_default = getGlobalStyleHook("co-editor-image-loading", (token) => {
|
|
|
22
22
|
display: "inline",
|
|
23
23
|
height: 42,
|
|
24
24
|
width: 42,
|
|
25
|
-
animationName:
|
|
25
|
+
animationName: contrarotation,
|
|
26
26
|
animationDuration: "2s",
|
|
27
27
|
animationTimingFunction: "linear",
|
|
28
28
|
animationIterationCount: "infinite",
|
|
29
29
|
circle: {
|
|
30
|
-
animationName:
|
|
30
|
+
animationName: spinner,
|
|
31
31
|
animationDuration: "1.5s",
|
|
32
32
|
animationTimingFunction: "ease-in-out",
|
|
33
33
|
animationIterationCount: "infinite",
|
|
@@ -16,9 +16,7 @@ class ImageUploader extends Module {
|
|
|
16
16
|
this.quill = quill;
|
|
17
17
|
this.options = options;
|
|
18
18
|
if (typeof this.options.upload !== "function")
|
|
19
|
-
console.warn(
|
|
20
|
-
"[Missing config] upload function that returns a promise is required"
|
|
21
|
-
);
|
|
19
|
+
console.warn("[Missing config] upload function that returns a promise is required");
|
|
22
20
|
const toolbar = this.quill.getModule("toolbar");
|
|
23
21
|
if (toolbar) {
|
|
24
22
|
toolbar.addHandler("image", this.selectLocalImage);
|
|
@@ -1,25 +1,28 @@
|
|
|
1
1
|
import Quill from 'quill';
|
|
2
2
|
import { ImageUploader } from './modules/image-uploader/image-uploader.js';
|
|
3
|
-
import stdin_default$
|
|
3
|
+
import stdin_default$2 from './modules/custom-list.js';
|
|
4
4
|
import { Formula } from './formats/formula.js';
|
|
5
5
|
import { SizeStyle } from './formats/size.js';
|
|
6
6
|
import { FontStyle } from './formats/font.js';
|
|
7
7
|
import { Link } from './formats/link.js';
|
|
8
8
|
import { AlignStyle } from './formats/align.js';
|
|
9
|
-
import stdin_default from './formats/video.js';
|
|
9
|
+
import stdin_default$1 from './formats/video.js';
|
|
10
|
+
import stdin_default from './formats/image.js';
|
|
10
11
|
|
|
11
12
|
function register() {
|
|
12
13
|
Quill.register(
|
|
13
14
|
{
|
|
14
15
|
"modules/imageUploader": ImageUploader,
|
|
15
|
-
"modules/customList": stdin_default$
|
|
16
|
+
"modules/customList": stdin_default$2,
|
|
16
17
|
"formats/formula": Formula,
|
|
17
18
|
"formats/size": SizeStyle,
|
|
18
19
|
"formats/font": FontStyle,
|
|
19
20
|
"formats/link": Link,
|
|
20
21
|
"formats/align": AlignStyle,
|
|
21
22
|
// 'formats/indent': IndentStyle,
|
|
22
|
-
"formats/video": stdin_default
|
|
23
|
+
"formats/video": stdin_default$1,
|
|
24
|
+
"formats/image": stdin_default
|
|
25
|
+
// 'formats/list': List,
|
|
23
26
|
},
|
|
24
27
|
true
|
|
25
28
|
);
|
|
@@ -267,11 +267,7 @@ const getEditorStyle = (token) => {
|
|
|
267
267
|
};
|
|
268
268
|
};
|
|
269
269
|
var stdin_default = getStyleHook("Editor", (token) => {
|
|
270
|
-
return [
|
|
271
|
-
getEditorStyle(token),
|
|
272
|
-
getEditorToolbarStyle(token),
|
|
273
|
-
getEditorButtonStyle(token)
|
|
274
|
-
];
|
|
270
|
+
return [getEditorStyle(token), getEditorToolbarStyle(token), getEditorButtonStyle(token)];
|
|
275
271
|
});
|
|
276
272
|
|
|
277
273
|
export { stdin_default as default, getQuillArticleStyle };
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import { type CheckboxValueType } from 'element-plus';
|
|
2
|
-
import { Panel } from '../../../panel';
|
|
3
1
|
type __VLS_Props = {
|
|
4
2
|
modelValue: any[];
|
|
5
3
|
options: {
|
|
@@ -8,26 +6,10 @@ type __VLS_Props = {
|
|
|
8
6
|
}[];
|
|
9
7
|
maxHeight?: string | number;
|
|
10
8
|
};
|
|
11
|
-
declare const token: import("vue").ComputedRef<import("../../..").GlobalToken>;
|
|
12
|
-
declare const checkAll: import("vue").Ref<boolean, boolean>;
|
|
13
|
-
declare const isIndeterminate: import("vue").Ref<boolean, boolean>;
|
|
14
|
-
declare const handleCheckAllChange: (val: CheckboxValueType) => void;
|
|
15
|
-
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
16
9
|
declare var __VLS_14: {};
|
|
17
|
-
type __VLS_Slots =
|
|
10
|
+
type __VLS_Slots = {} & {
|
|
18
11
|
default?: (props: typeof __VLS_14) => any;
|
|
19
|
-
}
|
|
20
|
-
declare const __VLS_self: import("vue").DefineComponent<__VLS_Props, {
|
|
21
|
-
Panel: typeof Panel;
|
|
22
|
-
token: typeof token;
|
|
23
|
-
checkAll: typeof checkAll;
|
|
24
|
-
isIndeterminate: typeof isIndeterminate;
|
|
25
|
-
handleCheckAllChange: typeof handleCheckAllChange;
|
|
26
|
-
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
27
|
-
"update:modelValue": (value: any[]) => any;
|
|
28
|
-
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
29
|
-
"onUpdate:modelValue"?: ((value: any[]) => any) | undefined;
|
|
30
|
-
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
};
|
|
31
13
|
declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
32
14
|
"update:modelValue": (value: any[]) => any;
|
|
33
15
|
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
@@ -56,8 +56,8 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
56
56
|
onChange: handleCheckAllChange
|
|
57
57
|
}, {
|
|
58
58
|
default: withCtx(() => _cache[1] || (_cache[1] = [createTextVNode(" \u5168\u9009 ")])),
|
|
59
|
-
_: 1
|
|
60
|
-
|
|
59
|
+
_: 1,
|
|
60
|
+
__: [1]
|
|
61
61
|
}, 8, ["modelValue", "indeterminate"]), createElementVNode("div", {
|
|
62
62
|
style: normalizeStyle({
|
|
63
63
|
marginLeft: "auto",
|
|
@@ -2,7 +2,7 @@ import { type TreeInstance } from 'element-plus';
|
|
|
2
2
|
import { type FieldComponentCommonProps } from '../common';
|
|
3
3
|
import { FieldSelectProps, FieldSelectSlots, type FieldSelectEmits, type FieldSelectExpose } from '../select/select';
|
|
4
4
|
import { ExtractPropTypes, PropType } from 'vue';
|
|
5
|
-
declare const elTreeProps: {
|
|
5
|
+
export declare const elTreeProps: {
|
|
6
6
|
data: {
|
|
7
7
|
type: PropType<Array<{
|
|
8
8
|
[key: string]: any;
|
|
@@ -106,4 +106,3 @@ export type FieldTreeSelectEmits = FieldSelectEmits & {
|
|
|
106
106
|
(e: 'node-drop', ...args: any[]): void;
|
|
107
107
|
};
|
|
108
108
|
export type FieldTreeSelectExpose = FieldSelectExpose & TreeInstance;
|
|
109
|
-
export {};
|
|
@@ -1 +1,70 @@
|
|
|
1
|
+
import { iconPropType } from 'element-plus/es/utils/index.mjs';
|
|
1
2
|
|
|
3
|
+
const elTreeProps = {
|
|
4
|
+
data: {
|
|
5
|
+
type: Array,
|
|
6
|
+
default: () => []
|
|
7
|
+
},
|
|
8
|
+
emptyText: {
|
|
9
|
+
type: String
|
|
10
|
+
},
|
|
11
|
+
renderAfterExpand: {
|
|
12
|
+
type: Boolean,
|
|
13
|
+
default: true
|
|
14
|
+
},
|
|
15
|
+
nodeKey: String,
|
|
16
|
+
checkStrictly: Boolean,
|
|
17
|
+
defaultExpandAll: Boolean,
|
|
18
|
+
expandOnClickNode: {
|
|
19
|
+
type: Boolean,
|
|
20
|
+
default: true
|
|
21
|
+
},
|
|
22
|
+
checkOnClickNode: Boolean,
|
|
23
|
+
checkDescendants: {
|
|
24
|
+
type: Boolean,
|
|
25
|
+
default: false
|
|
26
|
+
},
|
|
27
|
+
autoExpandParent: {
|
|
28
|
+
type: Boolean,
|
|
29
|
+
default: true
|
|
30
|
+
},
|
|
31
|
+
defaultCheckedKeys: Array,
|
|
32
|
+
defaultExpandedKeys: Array,
|
|
33
|
+
currentNodeKey: [String, Number],
|
|
34
|
+
renderContent: Function,
|
|
35
|
+
showCheckbox: {
|
|
36
|
+
type: Boolean,
|
|
37
|
+
default: false
|
|
38
|
+
},
|
|
39
|
+
draggable: {
|
|
40
|
+
type: Boolean,
|
|
41
|
+
default: false
|
|
42
|
+
},
|
|
43
|
+
allowDrag: Function,
|
|
44
|
+
allowDrop: Function,
|
|
45
|
+
props: {
|
|
46
|
+
type: Object,
|
|
47
|
+
default: () => ({
|
|
48
|
+
children: "children",
|
|
49
|
+
label: "label",
|
|
50
|
+
disabled: "disabled"
|
|
51
|
+
})
|
|
52
|
+
},
|
|
53
|
+
lazy: {
|
|
54
|
+
type: Boolean,
|
|
55
|
+
default: false
|
|
56
|
+
},
|
|
57
|
+
highlightCurrent: Boolean,
|
|
58
|
+
load: Function,
|
|
59
|
+
filterNodeMethod: Function,
|
|
60
|
+
accordion: Boolean,
|
|
61
|
+
indent: {
|
|
62
|
+
type: Number,
|
|
63
|
+
default: 18
|
|
64
|
+
},
|
|
65
|
+
icon: {
|
|
66
|
+
type: iconPropType
|
|
67
|
+
}
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
export { elTreeProps };
|
|
@@ -45,7 +45,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
45
45
|
class: normalizeClass([unref(hashId), unref(prefixCls), `is-${_ctx.size}`]),
|
|
46
46
|
title: _ctx.title || _ctx.src
|
|
47
47
|
}, [createVNode(stdin_default$2, {
|
|
48
|
-
name: "
|
|
48
|
+
name: "co:document"
|
|
49
49
|
}), createElementVNode("div", {
|
|
50
50
|
class: normalizeClass([`${unref(prefixCls)}-filename`])
|
|
51
51
|
}, toDisplayString(_ctx.name), 3
|
|
@@ -239,7 +239,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
239
239
|
key: 1
|
|
240
240
|
})]),
|
|
241
241
|
default: withCtx(() => [createVNode(stdin_default$1, {
|
|
242
|
-
name: "
|
|
242
|
+
name: "co:help",
|
|
243
243
|
class: normalizeClass(`${unref(prefixCls)}-item-label-icon`),
|
|
244
244
|
size: "md"
|
|
245
245
|
}, null, 8, ["class"])]),
|
|
@@ -4,11 +4,7 @@ import { provide, reactive, toRef, useTemplateRef, ref } from 'vue';
|
|
|
4
4
|
import { createMergedExpose } from '../../utils/vue.js';
|
|
5
5
|
|
|
6
6
|
function useFormTemplate(props, options = {}) {
|
|
7
|
-
const elFormProps = reactiveOmit(
|
|
8
|
-
props,
|
|
9
|
-
...formPropsOmit,
|
|
10
|
-
...options.omittedProps || []
|
|
11
|
-
);
|
|
7
|
+
const elFormProps = reactiveOmit(props, ...formPropsOmit, ...options.omittedProps || []);
|
|
12
8
|
const resetList = [];
|
|
13
9
|
const addResetField = (reset2) => {
|
|
14
10
|
resetList.unshift(reset2);
|
|
@@ -62,11 +58,7 @@ function useFormTemplate(props, options = {}) {
|
|
|
62
58
|
submit,
|
|
63
59
|
reset
|
|
64
60
|
};
|
|
65
|
-
const expose = createMergedExpose(
|
|
66
|
-
formExposeKeys,
|
|
67
|
-
() => elFormRef.value,
|
|
68
|
-
customExpose
|
|
69
|
-
);
|
|
61
|
+
const expose = createMergedExpose(formExposeKeys, () => elFormRef.value, customExpose);
|
|
70
62
|
return {
|
|
71
63
|
elFormProps,
|
|
72
64
|
expose,
|
|
@@ -473,7 +473,6 @@ declare const __VLS_component: import("vue").DefineComponent<import("vue").Extra
|
|
|
473
473
|
$router: import("vue-router").TypesConfig extends Record<"$router", infer T> ? T : import("vue-router").Router;
|
|
474
474
|
$pinia: import("pinia").Pinia;
|
|
475
475
|
_pStores?: Record<string, import("pinia").StoreGeneric>;
|
|
476
|
-
$cosey: import("../..").GlobalConfig;
|
|
477
476
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
478
477
|
open: () => any;
|
|
479
478
|
close: () => any;
|
|
@@ -41,7 +41,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
41
41
|
"modelValue": visible.value,
|
|
42
42
|
"onUpdate:modelValue": $event => visible.value = $event,
|
|
43
43
|
"style": {
|
|
44
|
-
maxWidth: "calc(100vw - 32px)"
|
|
44
|
+
maxWidth: props.fullscreen ? null : "calc(100vw - 32px)"
|
|
45
45
|
},
|
|
46
46
|
"width": width.value,
|
|
47
47
|
"append-to-body": true,
|
|
@@ -482,7 +482,6 @@ declare const _FormDialog: {
|
|
|
482
482
|
$router: import("vue-router").TypesConfig extends Record<"$router", infer T> ? T : import("vue-router").Router;
|
|
483
483
|
$pinia: import("pinia").Pinia;
|
|
484
484
|
_pStores?: Record<string, import("pinia").StoreGeneric>;
|
|
485
|
-
$cosey: import("../..").GlobalConfig;
|
|
486
485
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
487
486
|
open: () => any;
|
|
488
487
|
close: () => any;
|
|
@@ -1005,7 +1004,6 @@ declare const _FormDialog: {
|
|
|
1005
1004
|
$router: import("vue-router").TypesConfig extends Record<"$router", infer T> ? T : import("vue-router").Router;
|
|
1006
1005
|
$pinia: import("pinia").Pinia;
|
|
1007
1006
|
_pStores?: Record<string, import("pinia").StoreGeneric>;
|
|
1008
|
-
$cosey: import("../..").GlobalConfig;
|
|
1009
1007
|
}, {}, {}, {}, {
|
|
1010
1008
|
width: import("./form-dialog").FormDialogWidth;
|
|
1011
1009
|
overflow: boolean;
|
|
@@ -1517,7 +1515,6 @@ declare const _FormDialog: {
|
|
|
1517
1515
|
$router: import("vue-router").TypesConfig extends Record<"$router", infer T> ? T : import("vue-router").Router;
|
|
1518
1516
|
$pinia: import("pinia").Pinia;
|
|
1519
1517
|
_pStores?: Record<string, import("pinia").StoreGeneric>;
|
|
1520
|
-
$cosey: import("../..").GlobalConfig;
|
|
1521
1518
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
1522
1519
|
open: () => any;
|
|
1523
1520
|
close: () => any;
|
|
@@ -114,7 +114,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
114
114
|
onClick: handleToggle
|
|
115
115
|
}, [_ctx.collapsible ? (openBlock(), createBlock(stdin_default$1, {
|
|
116
116
|
key: 0,
|
|
117
|
-
name: innerCollapsed.value ? "
|
|
117
|
+
name: innerCollapsed.value ? "co:caret-up" : "co:caret-down",
|
|
118
118
|
size: "xl"
|
|
119
119
|
}, null, 8, ["name"])) : createCommentVNode("v-if", true), createTextVNode(" " + toDisplayString(_ctx.title), 1
|
|
120
120
|
/* TEXT */)], 4
|
|
@@ -5,11 +5,6 @@ const defaultFormListProps = {
|
|
|
5
5
|
modelValue: () => [],
|
|
6
6
|
addText: "\u65B0\u589E"
|
|
7
7
|
};
|
|
8
|
-
const formListExposeKeys = [
|
|
9
|
-
...formItemExposeKeys,
|
|
10
|
-
"add",
|
|
11
|
-
"remove",
|
|
12
|
-
"move"
|
|
13
|
-
];
|
|
8
|
+
const formListExposeKeys = [...formItemExposeKeys, "add", "remove", "move"];
|
|
14
9
|
|
|
15
10
|
export { defaultFormListProps, formListExposeKeys };
|
|
@@ -305,7 +305,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
305
305
|
"onClick": () => remove(index)
|
|
306
306
|
}, {
|
|
307
307
|
default: () => [createVNode(_Icon, {
|
|
308
|
-
"name": "
|
|
308
|
+
"name": "co:trash-can",
|
|
309
309
|
"size": "lg"
|
|
310
310
|
}, null)]
|
|
311
311
|
})]
|
|
@@ -320,7 +320,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
320
320
|
"onClick": handleAdd
|
|
321
321
|
}, {
|
|
322
322
|
default: () => [createVNode(_Icon, {
|
|
323
|
-
"name": "
|
|
323
|
+
"name": "co:add-large",
|
|
324
324
|
"class": `${prefixCls.value}-plus-icon`
|
|
325
325
|
}, null), props.addText]
|
|
326
326
|
})])])],
|
|
@@ -112,15 +112,15 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
112
112
|
type: "primary",
|
|
113
113
|
loading: unref(submitting)
|
|
114
114
|
}, {
|
|
115
|
-
default: withCtx(() => _cache[2] || (_cache[2] = [createTextVNode("
|
|
116
|
-
_: 1
|
|
117
|
-
|
|
115
|
+
default: withCtx(() => _cache[2] || (_cache[2] = [createTextVNode("\u67E5\u8BE2")])),
|
|
116
|
+
_: 1,
|
|
117
|
+
__: [2]
|
|
118
118
|
}, 8, ["loading"]), createVNode(unref(ElButton), {
|
|
119
119
|
onClick: unref(reset)
|
|
120
120
|
}, {
|
|
121
121
|
default: withCtx(() => _cache[3] || (_cache[3] = [createTextVNode("\u91CD\u7F6E")])),
|
|
122
|
-
_: 1
|
|
123
|
-
|
|
122
|
+
_: 1,
|
|
123
|
+
__: [3]
|
|
124
124
|
}, 8, ["onClick"])]), showToggle.value ? (openBlock(), createBlock(unref(_Toggle), {
|
|
125
125
|
key: 0,
|
|
126
126
|
modelValue: unref(innerCollapsed),
|
|
@@ -187,7 +187,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
187
187
|
}, [tableTree.value.length === 0 ? (openBlock(), createElementBlock("div", {
|
|
188
188
|
key: 0,
|
|
189
189
|
class: normalizeClass(`${unref(prefixCls)}-empty`)
|
|
190
|
-
}, "
|
|
190
|
+
}, "\u6682\u65E0\u6570\u636E", 2
|
|
191
191
|
/* CLASS */)) : (openBlock(), createElementBlock("table", _hoisted_1, [_ctx.showCheckbox && !_ctx.checkStrictly ? (openBlock(), createElementBlock("thead", _hoisted_2, [createElementVNode("tr", null, [createElementVNode("td", {
|
|
192
192
|
colspan: maxLevel.value
|
|
193
193
|
}, [createElementVNode("div", {
|
|
@@ -198,12 +198,15 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
198
198
|
onChange: unref(onCheckAllChange)
|
|
199
199
|
}, {
|
|
200
200
|
default: withCtx(() => _cache[0] || (_cache[0] = [createTextVNode(" \u6240\u6709 ")])),
|
|
201
|
-
_: 1
|
|
202
|
-
|
|
201
|
+
_: 1,
|
|
202
|
+
__: [0]
|
|
203
203
|
}, 8, ["model-value", "indeterminate", "onChange"])], 2
|
|
204
|
-
/* CLASS */)], 8, _hoisted_3)])])) : createCommentVNode("v-if", true), createElementVNode("tbody", null, [(openBlock(true), createElementBlock(Fragment, null, renderList(tableTree.value, row => {
|
|
205
|
-
return openBlock(), createElementBlock("tr",
|
|
204
|
+
/* CLASS */)], 8, _hoisted_3)])])) : createCommentVNode("v-if", true), createElementVNode("tbody", null, [(openBlock(true), createElementBlock(Fragment, null, renderList(tableTree.value, (row, i) => {
|
|
205
|
+
return openBlock(), createElementBlock("tr", {
|
|
206
|
+
key: i
|
|
207
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(row, (node, j) => {
|
|
206
208
|
return openBlock(), createElementBlock("td", {
|
|
209
|
+
key: j,
|
|
207
210
|
colspan: node.reverseLevel === 1 ? maxLevel.value - node.level + 1 : 1,
|
|
208
211
|
rowspan: node.leafCount
|
|
209
212
|
}, [node.reverseLevel !== 1 || !_ctx.mergeLast ? (openBlock(), createElementBlock("div", {
|
|
@@ -229,8 +232,9 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
229
232
|
}, [renderSlot(_ctx.$slots, "node", {}, () => [createTextVNode(toDisplayString(node.data[propNames.value.label]), 1
|
|
230
233
|
/* TEXT */)])], 2
|
|
231
234
|
/* CLASS */))], 2
|
|
232
|
-
/* CLASS */)) : (openBlock(), createElementBlock("div", _hoisted_5, [(openBlock(true), createElementBlock(Fragment, null, renderList(node.parent.children, _node => {
|
|
235
|
+
/* CLASS */)) : (openBlock(), createElementBlock("div", _hoisted_5, [(openBlock(true), createElementBlock(Fragment, null, renderList(node.parent.children, (_node, k) => {
|
|
233
236
|
return openBlock(), createElementBlock("div", {
|
|
237
|
+
key: k,
|
|
234
238
|
class: normalizeClass(`${unref(prefixCls)}-node`)
|
|
235
239
|
}, [_ctx.showCheckbox ? (openBlock(), createBlock(_component_el_checkbox, {
|
|
236
240
|
key: 0,
|
|
@@ -252,12 +256,12 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
252
256
|
}, toDisplayString(_node.data[propNames.value.label]), 3
|
|
253
257
|
/* TEXT, CLASS */)])], 2
|
|
254
258
|
/* CLASS */);
|
|
255
|
-
}),
|
|
256
|
-
/*
|
|
257
|
-
}),
|
|
258
|
-
/*
|
|
259
|
-
}),
|
|
260
|
-
/*
|
|
259
|
+
}), 128
|
|
260
|
+
/* KEYED_FRAGMENT */))]))], 8, _hoisted_4);
|
|
261
|
+
}), 128
|
|
262
|
+
/* KEYED_FRAGMENT */))]);
|
|
263
|
+
}), 128
|
|
264
|
+
/* KEYED_FRAGMENT */))])]))], 2
|
|
261
265
|
/* CLASS */);
|
|
262
266
|
};
|
|
263
267
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent, computed, createElementBlock, openBlock } from 'vue';
|
|
2
|
-
import {
|
|
2
|
+
import { iconifyIconsSets } from './iconify-icon.js';
|
|
3
3
|
|
|
4
4
|
const _hoisted_1 = ["viewBox", "innerHTML"];
|
|
5
5
|
var stdin_default = /* @__PURE__ */defineComponent({
|
|
@@ -19,10 +19,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
19
19
|
},
|
|
20
20
|
setup(__props) {
|
|
21
21
|
const props = __props;
|
|
22
|
-
const
|
|
23
|
-
mdi: icons
|
|
24
|
-
};
|
|
25
|
-
const iconSet = computed(() => iconSets[props.prefix]);
|
|
22
|
+
const iconSet = computed(() => iconifyIconsSets[props.prefix]);
|
|
26
23
|
const viewBox = computed(() => `0 0 ${iconSet.value?.width ?? 16} ${iconSet.value?.height ?? 16}`);
|
|
27
24
|
const path = computed(() => {
|
|
28
25
|
const icon = iconSet.value?.icons[props.name];
|