@nightshadeui/components 3.1.0 → 3.2.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.
Files changed (139) hide show
  1. package/README.md +21 -0
  2. package/css.d.ts +2 -0
  3. package/dist/_virtual/_plugin-vue_export-helper.js +7 -0
  4. package/dist/_virtual/_rolldown/runtime.js +10 -0
  5. package/dist/components/BaseMenu.css +1 -0
  6. package/dist/components/BaseMenu.js +108 -0
  7. package/dist/components/BaseMenu.vue.d.ts +21 -8
  8. package/dist/components/BaseMenu.vue.d.ts.map +1 -1
  9. package/dist/components/Btn.css +1 -0
  10. package/dist/components/Btn.js +186 -0
  11. package/dist/components/Btn.vue.d.ts +38 -2
  12. package/dist/components/Btn.vue.d.ts.map +1 -1
  13. package/dist/components/Bubble.css +1 -0
  14. package/dist/components/Bubble.js +37 -0
  15. package/dist/components/Bubble.vue.d.ts +12 -2
  16. package/dist/components/Bubble.vue.d.ts.map +1 -1
  17. package/dist/components/Checkbox.css +1 -0
  18. package/dist/components/Checkbox.js +116 -0
  19. package/dist/components/Checkbox.vue.d.ts +15 -3
  20. package/dist/components/Checkbox.vue.d.ts.map +1 -1
  21. package/dist/components/Chip.css +1 -0
  22. package/dist/components/Chip.js +91 -0
  23. package/dist/components/Chip.vue.d.ts +16 -2
  24. package/dist/components/Chip.vue.d.ts.map +1 -1
  25. package/dist/components/ContextMenu.js +56 -0
  26. package/dist/components/ContextMenu.vue.d.ts +28 -8
  27. package/dist/components/ContextMenu.vue.d.ts.map +1 -1
  28. package/dist/components/ContextPopup.js +166 -0
  29. package/dist/components/ContextPopup.vue.d.ts +23 -2
  30. package/dist/components/ContextPopup.vue.d.ts.map +1 -1
  31. package/dist/components/Filler.css +1 -0
  32. package/dist/components/Filler.js +18 -0
  33. package/dist/components/Filler.vue.d.ts +6 -2
  34. package/dist/components/Filler.vue.d.ts.map +1 -1
  35. package/dist/components/HGroup.css +1 -0
  36. package/dist/components/HGroup.js +44 -0
  37. package/dist/components/HGroup.vue.d.ts +21 -8
  38. package/dist/components/HGroup.vue.d.ts.map +1 -1
  39. package/dist/components/InputBase.css +1 -0
  40. package/dist/components/InputBase.js +115 -0
  41. package/dist/components/InputBase.vue.d.ts +16 -2
  42. package/dist/components/InputBase.vue.d.ts.map +1 -1
  43. package/dist/components/InputGroup.css +1 -0
  44. package/dist/components/InputGroup.js +21 -0
  45. package/dist/components/InputGroup.vue.d.ts +12 -2
  46. package/dist/components/InputGroup.vue.d.ts.map +1 -1
  47. package/dist/components/InputSelect.css +1 -0
  48. package/dist/components/InputSelect.js +110 -0
  49. package/dist/components/InputSelect.vue.d.ts +18 -2
  50. package/dist/components/InputSelect.vue.d.ts.map +1 -1
  51. package/dist/components/InputText.css +1 -0
  52. package/dist/components/InputText.js +77 -0
  53. package/dist/components/InputText.vue.d.ts +18 -2
  54. package/dist/components/InputText.vue.d.ts.map +1 -1
  55. package/dist/components/InputTextarea.css +1 -0
  56. package/dist/components/InputTextarea.js +80 -0
  57. package/dist/components/InputTextarea.vue.d.ts +18 -2
  58. package/dist/components/InputTextarea.vue.d.ts.map +1 -1
  59. package/dist/components/ModalOverlay.css +1 -0
  60. package/dist/components/ModalOverlay.js +45 -0
  61. package/dist/components/ModalOverlay.vue.d.ts +12 -2
  62. package/dist/components/ModalOverlay.vue.d.ts.map +1 -1
  63. package/dist/components/RouterBtn.js +39 -0
  64. package/dist/components/RouterBtn.vue.d.ts +10 -2
  65. package/dist/components/RouterBtn.vue.d.ts.map +1 -1
  66. package/dist/components/Slider.css +1 -0
  67. package/dist/components/Slider.js +326 -0
  68. package/dist/components/Slider.vue.d.ts +10 -2
  69. package/dist/components/Slider.vue.d.ts.map +1 -1
  70. package/dist/components/Tab.css +1 -0
  71. package/dist/components/Tab.js +56 -0
  72. package/dist/components/Tab.vue.d.ts +12 -2
  73. package/dist/components/Tab.vue.d.ts.map +1 -1
  74. package/dist/components/TabCap.css +1 -0
  75. package/dist/components/TabCap.js +28 -0
  76. package/dist/components/TabCap.vue.d.ts +6 -2
  77. package/dist/components/TabCap.vue.d.ts.map +1 -1
  78. package/dist/components/Toggle.css +1 -0
  79. package/dist/components/Toggle.js +102 -0
  80. package/dist/components/Toggle.vue.d.ts +6 -2
  81. package/dist/components/Toggle.vue.d.ts.map +1 -1
  82. package/dist/components/ToolPanel.css +1 -0
  83. package/dist/components/ToolPanel.js +33 -0
  84. package/dist/components/ToolPanel.vue.d.ts +12 -2
  85. package/dist/components/ToolPanel.vue.d.ts.map +1 -1
  86. package/dist/components/Tooltip.css +1 -0
  87. package/dist/components/Tooltip.js +97 -0
  88. package/dist/components/Tooltip.vue.d.ts +225 -0
  89. package/dist/components/Tooltip.vue.d.ts.map +1 -0
  90. package/dist/components/VGroup.css +1 -0
  91. package/dist/components/VGroup.js +36 -0
  92. package/dist/components/VGroup.vue.d.ts +21 -8
  93. package/dist/components/VGroup.vue.d.ts.map +1 -1
  94. package/dist/components/index.d.ts +2 -1
  95. package/dist/components/index.d.ts.map +1 -1
  96. package/dist/components/index.js +51 -0
  97. package/dist/components.css +39 -1
  98. package/dist/directives/index.d.ts +2 -0
  99. package/dist/directives/index.d.ts.map +1 -0
  100. package/dist/directives/tooltip.d.ts +14 -0
  101. package/dist/directives/tooltip.d.ts.map +1 -0
  102. package/dist/directives/tooltip.js +23 -0
  103. package/dist/glyphs/GlyphCheck.js +17 -0
  104. package/dist/glyphs/GlyphCheck.vue.d.ts +2 -1
  105. package/dist/glyphs/GlyphCheck.vue.d.ts.map +1 -1
  106. package/dist/glyphs/GlyphXmark.js +17 -0
  107. package/dist/glyphs/GlyphXmark.vue.d.ts +2 -1
  108. package/dist/glyphs/GlyphXmark.vue.d.ts.map +1 -1
  109. package/dist/helpers/props.js +28 -0
  110. package/dist/index.d.ts +1 -0
  111. package/dist/index.d.ts.map +1 -1
  112. package/dist/index.js +28 -0
  113. package/package.json +14 -8
  114. package/src/components/BaseMenu.vue +36 -29
  115. package/src/components/Btn.vue +197 -191
  116. package/src/components/Bubble.vue +110 -103
  117. package/src/components/Checkbox.vue +93 -86
  118. package/src/components/Chip.vue +109 -102
  119. package/src/components/ContextPopup.vue +9 -1
  120. package/src/components/Filler.vue +21 -14
  121. package/src/components/HGroup.vue +47 -41
  122. package/src/components/InputBase.vue +137 -130
  123. package/src/components/InputGroup.vue +26 -16
  124. package/src/components/InputSelect.vue +28 -21
  125. package/src/components/InputText.vue +24 -17
  126. package/src/components/InputTextarea.vue +31 -24
  127. package/src/components/ModalOverlay.vue +21 -14
  128. package/src/components/Slider.vue +258 -249
  129. package/src/components/Tab.vue +73 -66
  130. package/src/components/TabCap.vue +20 -13
  131. package/src/components/Toggle.vue +102 -95
  132. package/src/components/ToolPanel.vue +36 -35
  133. package/src/components/Tooltip.vue +184 -0
  134. package/src/components/VGroup.vue +43 -37
  135. package/src/components/index.ts +2 -0
  136. package/src/directives/index.ts +1 -0
  137. package/src/directives/tooltip.ts +50 -0
  138. package/src/index.ts +1 -0
  139. package/dist/components.mjs +0 -1719
@@ -1,4 +1,10 @@
1
- declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
1
+ declare const _default: typeof __VLS_export;
2
+ export default _default;
3
+ export type __VLS_LocalComponents = {};
4
+ export type __VLS_GlobalComponents = import('vue').GlobalComponents;
5
+ export type __VLS_LocalDirectives = {};
6
+ export type __VLS_Slots = ReturnType<typeof __VLS_template>["__VLS_Slots"];
7
+ declare const __VLS_export: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
2
8
  mark: {
3
9
  type: StringConstructor;
4
10
  default: string;
@@ -48,7 +54,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
48
54
  hover: boolean;
49
55
  focus: boolean;
50
56
  }, {
51
- markComponent(): import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, SVGSVGElement> | null;
57
+ markComponent(): import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any> | null;
52
58
  isActive(): boolean;
53
59
  baseStyle(): {
54
60
  tone: any;
@@ -133,5 +139,11 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
133
139
  mark: string;
134
140
  modelValue: boolean;
135
141
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
136
- export default _default;
142
+ declare function __VLS_template(): {
143
+ __VLS_Slots: {
144
+ active?: (props: {}) => any;
145
+ } & {
146
+ inactive?: (props: {}) => any;
147
+ };
148
+ };
137
149
  //# sourceMappingURL=Checkbox.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Checkbox.vue.d.ts","sourceRoot":"","sources":["../../src/components/Checkbox.vue"],"names":[],"mappings":"AAuCA;"}
1
+ {"version":3,"file":"Checkbox.vue.d.ts","sourceRoot":"","sources":["../../src/components/Checkbox.vue"],"names":[],"mappings":"AAuCA;wBAkR0B,OAAO,YAAY;;oCAE/B,EAAE;qCACF,OAAO,KAAK,EAAE,gBAAgB;oCAG9B,EAAE;0BAyHF,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC,aAAa,CAAC;AAE9D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAwFG;AAhNH;;iBA8Ga,CAAC,KAAK,IAAgB,KAAK,GAAG;;mBAC5B,CAAC,KAAK,IAAgB,KAAK,GAAG;;EAM5C"}
@@ -0,0 +1 @@
1
+ @layer nightshade;@layer nightshade-components{.Chip[data-v-6cd72d70]{--Chip-size:var(--input-major-height);--Chip-padding:var(--input-major-padding);--Chip-gap:var(--input-gap);--Chip-font-size:var(--input-font-size);--Chip-background:var(--tone-tint);--Chip-text:var(--tone-tint-text);--Chip-icon:var(--tone-tint-text);--Chip-border-size:0px;--Chip-border:transparent;--Chip-outline:transparent;--Chip-radius:var(--radius-m);--Chip-box-shadow:0 1px 1px var(--shadow-light);appearance:none;align-items:center;gap:var(--Chip-gap);box-sizing:border-box;height:var(--Chip-size);padding:0 calc(var(--Chip-padding) - var(--Chip-border-size));border:var(--Chip-border-size) solid var(--Chip-border);border-radius:var(--Chip-radius);outline:var(--input-outline-size) solid var(--Chip-outline);outline-offset:var(--input-outline-offset);background:var(--Chip-background);box-shadow:var(--Chip-box-shadow);color:var(--Chip-text);font-family:inherit;font-size:var(--Chip-font-size);white-space:nowrap;cursor:pointer;-webkit-user-select:none;user-select:none;flex-shrink:0;margin:0;line-height:1;transition:background-color .2s,color .2s,border-color .2s,border-radius .3s;display:inline-flex;position:relative}.Chip[data-v-6cd72d70]:after{content:"";border-radius:inherit;background:var(--input-hover-overlay);mix-blend-mode:color-dodge;pointer-events:none;opacity:0;position:absolute;inset:0}.Icon[data-v-6cd72d70]{color:var(--Chip-icon)}.Chip[data-v-6cd72d70]:not(.Chip-disabled):hover:after,.Chip-forceHover[data-v-6cd72d70]:after{opacity:1}.Chip[data-v-6cd72d70]:not(.Chip-disabled):focus-visible,.Chip-forceFocus[data-v-6cd72d70]{z-index:10;--Chip-outline:var(--tone-focus-outline);--Chip-border:var(--tone-focus-border)}.Chip-disabled[data-v-6cd72d70]{opacity:var(--input-disabled-opacity);filter:var(--input-disabled-filter);cursor:not-allowed}.Chip-round[data-v-6cd72d70]{--Chip-radius:calc(.5 * var(--Chip-size))}.Chip-outline[data-v-6cd72d70]{--Chip-border-size:var(--input-border-size);--Chip-border:var(--tone-border)}.Chip-flat[data-v-6cd72d70]{--Chip-box-shadow:none}.Chip-translucent[data-v-6cd72d70]{--Chip-background:color-mix(in srgb, var(--tone-tint), transparent var(--translucency-mix-medium));--Chip-box-shadow:0 0 3px var(--translucency-highlight) inset;-webkit-backdrop-filter:blur(var(--translucency-blur));backdrop-filter:blur(var(--translucency-blur))}}
@@ -0,0 +1,91 @@
1
+ import './Chip.css';
2
+ import { nightshadeMixin as e } from "../helpers/props.js";
3
+ /* empty css */
4
+ import t from "../_virtual/_plugin-vue_export-helper.js";
5
+ import { createBlock as n, createCommentVNode as r, createElementBlock as i, normalizeClass as a, openBlock as o, renderSlot as s, resolveDynamicComponent as c, toDisplayString as l, withCtx as u } from "vue";
6
+ // src/components/Chip.vue
7
+ var d = {
8
+ mixins: [e],
9
+ props: {
10
+ tagName: {
11
+ type: String,
12
+ default: "button"
13
+ },
14
+ label: { type: String },
15
+ icon: { type: String },
16
+ tone: { type: String },
17
+ size: { type: String },
18
+ flat: {
19
+ type: Boolean,
20
+ default: !1
21
+ },
22
+ outline: {
23
+ type: Boolean,
24
+ default: !1
25
+ },
26
+ round: {
27
+ type: Boolean,
28
+ default: !1
29
+ },
30
+ translucent: {
31
+ type: Boolean,
32
+ default: !1
33
+ },
34
+ disabled: {
35
+ type: Boolean,
36
+ default: !1
37
+ },
38
+ forceFocus: {
39
+ type: Boolean,
40
+ default: !1
41
+ },
42
+ forceHover: {
43
+ type: Boolean,
44
+ default: !1
45
+ }
46
+ },
47
+ computed: { effectiveStyle() {
48
+ let { resolvedProps: e } = this;
49
+ return {
50
+ tone: e.tone,
51
+ size: e.size,
52
+ flat: e.flat,
53
+ outline: e.outline,
54
+ round: e.round,
55
+ translucent: e.translucent
56
+ };
57
+ } }
58
+ }, f = {
59
+ key: 1,
60
+ class: "Label"
61
+ };
62
+ function p(e, t, d, p, m, h) {
63
+ return o(), n(c(e.resolvedProps.tagName), {
64
+ class: a(["Chip InputElement", [
65
+ h.effectiveStyle.tone && `tone-${h.effectiveStyle.tone}`,
66
+ h.effectiveStyle.size && `input-size-${h.effectiveStyle.size}`,
67
+ {
68
+ "Chip-round": h.effectiveStyle.round,
69
+ "Chip-outline": h.effectiveStyle.outline,
70
+ "Chip-flat": h.effectiveStyle.flat,
71
+ "Chip-translucent": h.effectiveStyle.translucent,
72
+ "Chip-disabled": e.resolvedProps.disabled,
73
+ "Chip-forceFocus": e.resolvedProps.forceFocus,
74
+ "Chip-forceHover": e.resolvedProps.forceHover
75
+ }
76
+ ]]),
77
+ disabled: e.resolvedProps.disabled
78
+ }, {
79
+ default: u(() => [
80
+ s(e.$slots, "before", {}, void 0, !0),
81
+ s(e.$slots, "default", {}, () => [e.resolvedProps.icon ? (o(), i("i", {
82
+ key: 0,
83
+ class: a([e.resolvedProps.icon, "Icon"])
84
+ }, null, 2)) : r("", !0), e.resolvedProps.label ? (o(), i("span", f, l(e.resolvedProps.label), 1)) : r("", !0)], !0),
85
+ s(e.$slots, "after", {}, void 0, !0)
86
+ ]),
87
+ _: 3
88
+ }, 8, ["class", "disabled"]);
89
+ }
90
+ var m = /*#__PURE__*/ t(d, [["render", p], ["__scopeId", "data-v-6cd72d70"]]);
91
+ export { m as default };
@@ -1,4 +1,10 @@
1
- declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
1
+ declare const _default: typeof __VLS_export;
2
+ export default _default;
3
+ export type __VLS_LocalComponents = {};
4
+ export type __VLS_GlobalComponents = import('vue').GlobalComponents;
5
+ export type __VLS_LocalDirectives = {};
6
+ export type __VLS_Slots = ReturnType<typeof __VLS_template>["__VLS_Slots"];
7
+ declare const __VLS_export: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
2
8
  tagName: {
3
9
  type: StringConstructor;
4
10
  default: string;
@@ -116,5 +122,13 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
116
122
  forceFocus: boolean;
117
123
  forceHover: boolean;
118
124
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
119
- export default _default;
125
+ declare function __VLS_template(): {
126
+ __VLS_Slots: {
127
+ before?: (props: {}) => any;
128
+ } & {
129
+ default?: (props: {}) => any;
130
+ } & {
131
+ after?: (props: {}) => any;
132
+ };
133
+ };
120
134
  //# sourceMappingURL=Chip.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Chip.vue.d.ts","sourceRoot":"","sources":["../../src/components/Chip.vue"],"names":[],"mappings":"AAiCA;"}
1
+ {"version":3,"file":"Chip.vue.d.ts","sourceRoot":"","sources":["../../src/components/Chip.vue"],"names":[],"mappings":"AAiCA;wBA+M0B,OAAO,YAAY;;oCAE/B,EAAE;qCACF,OAAO,KAAK,EAAE,gBAAgB;oCAG9B,EAAE;0BAqFF,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC,aAAa,CAAC;AAE9D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAqCG;AAzHH;;iBAyEa,CAAC,KAAK,IAAgB,KAAK,GAAG;;kBAC7B,CAAC,KAAK,IAAgB,KAAK,GAAG;;gBAChC,CAAC,KAAK,IAAiB,KAAK,GAAG;;EAM1C"}
@@ -0,0 +1,56 @@
1
+ import { collectProps as e, nightshadeMixin as t } from "../helpers/props.js";
2
+ import n from "./BaseMenu.js";
3
+ import r from "./ContextPopup.js";
4
+ import i from "../_virtual/_plugin-vue_export-helper.js";
5
+ import { createBlock as a, createVNode as o, mergeProps as s, openBlock as c, resolveComponent as l, withCtx as u } from "vue";
6
+ // src/components/ContextMenu.vue
7
+ var d = {
8
+ components: {
9
+ ContextPopup: r,
10
+ BaseMenu: n
11
+ },
12
+ mixins: [t],
13
+ inheritAttrs: !1,
14
+ props: {
15
+ ...r.props,
16
+ ...n.props,
17
+ autoFocus: {
18
+ type: Boolean,
19
+ default: !0
20
+ }
21
+ },
22
+ emits: [...r.emits || [], ...n.emits || []],
23
+ computed: {
24
+ contextPopupProps() {
25
+ return e(this, r);
26
+ },
27
+ baseMenuProps() {
28
+ return e(this, n);
29
+ }
30
+ },
31
+ methods: {
32
+ hide() {
33
+ this.$refs.popup?.hide();
34
+ },
35
+ onActivate(e, t) {
36
+ this.$emit("activate", e, t);
37
+ }
38
+ }
39
+ };
40
+ function f(e, t, n, r, i, d) {
41
+ let f = l("BaseMenu"), p = l("ContextPopup");
42
+ return c(), a(p, s({ ref: "popup" }, d.contextPopupProps, {
43
+ onHide: t[0] ||= (t) => e.$emit("hide"),
44
+ onMouseenter: t[1] ||= (t) => e.$emit("mouseenter"),
45
+ onMouseleave: t[2] ||= (t) => e.$emit("mouseleave"),
46
+ onReady: t[3] ||= (t) => e.$emit("ready")
47
+ }), {
48
+ default: u(() => [o(f, s({ class: "ContextMenu" }, {
49
+ ...d.baseMenuProps,
50
+ ...e.$attrs
51
+ }, { onActivate: d.onActivate }), null, 16, ["onActivate"])]),
52
+ _: 1
53
+ }, 16);
54
+ }
55
+ var p = /*#__PURE__*/ i(d, [["render", f]]);
56
+ export { p as default };
@@ -1,4 +1,11 @@
1
- declare const _default: import('vue').DefineComponent<{}, {}, {}, {
1
+ import { default as ContextPopup } from './ContextPopup.vue';
2
+ import { default as BaseMenu } from './BaseMenu.vue';
3
+ declare const _default: typeof __VLS_export;
4
+ export default _default;
5
+ export type __VLS_LocalComponents = typeof __VLS_componentsOption;
6
+ export type __VLS_GlobalComponents = import('vue').GlobalComponents;
7
+ export type __VLS_LocalDirectives = {};
8
+ declare const __VLS_export: import('vue').DefineComponent<{}, {}, {}, {
2
9
  contextPopupProps(): Record<string, any>;
3
10
  baseMenuProps(): Record<string, any>;
4
11
  }, {
@@ -34,6 +41,9 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {
34
41
  anchorRef: {
35
42
  type: StringConstructor;
36
43
  };
44
+ anchorEl: {
45
+ default: null;
46
+ };
37
47
  anchorDir: {
38
48
  type: StringConstructor;
39
49
  default: string;
@@ -96,6 +106,9 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {
96
106
  anchorRef: {
97
107
  type: StringConstructor;
98
108
  };
109
+ anchorEl: {
110
+ default: null;
111
+ };
99
112
  anchorDir: {
100
113
  type: StringConstructor;
101
114
  default: string;
@@ -123,6 +136,7 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {
123
136
  arrowShown: boolean;
124
137
  overlayEnabled: boolean;
125
138
  overlayShown: boolean;
139
+ anchorEl: null;
126
140
  anchorDir: string;
127
141
  }, {}, {
128
142
  ModalOverlay: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
@@ -440,10 +454,15 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {
440
454
  type: StringConstructor;
441
455
  };
442
456
  gap: {
443
- type: StringConstructor;
444
- default: string;
457
+ type: (StringConstructor | NumberConstructor)[];
458
+ };
459
+ }>, {}, {}, {
460
+ gapStyle(): {
461
+ '--VGroup-gap'?: undefined;
462
+ } | {
463
+ '--VGroup-gap': string;
445
464
  };
446
- }>, {}, {}, {}, {}, {
465
+ }, {}, {
447
466
  inject: {
448
467
  $nightshade: {
449
468
  default: null;
@@ -465,15 +484,16 @@ declare const _default: import('vue').DefineComponent<{}, {}, {}, {
465
484
  type: StringConstructor;
466
485
  };
467
486
  gap: {
468
- type: StringConstructor;
469
- default: string;
487
+ type: (StringConstructor | NumberConstructor)[];
470
488
  };
471
489
  }>> & Readonly<{}>, {
472
490
  tagName: string;
473
491
  align: string;
474
- gap: string;
475
492
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
476
493
  }, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
477
494
  }, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
478
- export default _default;
495
+ declare namespace __VLS_componentsOption {
496
+ export { ContextPopup };
497
+ export { BaseMenu };
498
+ }
479
499
  //# sourceMappingURL=ContextMenu.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ContextMenu.vue.d.ts","sourceRoot":"","sources":["../../src/components/ContextMenu.vue"],"names":[],"mappings":"AAcA;"}
1
+ {"version":3,"file":"ContextMenu.vue.d.ts","sourceRoot":"","sources":["../../src/components/ContextMenu.vue"],"names":[],"mappings":"AAcA;wBAiF0B,OAAO,YAAY;;oCAM/B,OAAO,sBAAsB;qCAC7B,OAAO,KAAK,EAAE,gBAAgB;oCAG9B,EAAE;AAiGhB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qEA8CG;;;;;yBA3JsB,oBAAoB;qBADxB,gBAAgB"}
@@ -0,0 +1,166 @@
1
+ import { nightshadeMixin as e } from "../helpers/props.js";
2
+ import t from "./ModalOverlay.js";
3
+ import n from "../_virtual/_plugin-vue_export-helper.js";
4
+ import { createBlock as r, createCommentVNode as i, normalizeStyle as a, openBlock as o, renderSlot as s, resolveComponent as c, withCtx as l, withModifiers as u } from "vue";
5
+ // src/components/ContextPopup.vue
6
+ var d = {
7
+ components: { ModalOverlay: t },
8
+ mixins: [e],
9
+ props: {
10
+ dir: {
11
+ type: String,
12
+ default: "v"
13
+ },
14
+ align: {
15
+ type: String,
16
+ default: "auto"
17
+ },
18
+ anchorRef: { type: String },
19
+ anchorEl: { default: null },
20
+ anchorDir: {
21
+ type: String,
22
+ default: "middle"
23
+ },
24
+ overlayEnabled: {
25
+ type: Boolean,
26
+ default: !0
27
+ },
28
+ overlayShown: {
29
+ type: Boolean,
30
+ default: !0
31
+ },
32
+ arrowShown: {
33
+ type: Boolean,
34
+ default: !0
35
+ }
36
+ },
37
+ emits: [
38
+ "hide",
39
+ "mouseenter",
40
+ "mouseleave",
41
+ "ready"
42
+ ],
43
+ data() {
44
+ return {
45
+ pos: {
46
+ x: 0,
47
+ y: 0
48
+ },
49
+ actualDir: "bottom",
50
+ actualAlign: "start",
51
+ ready: !1
52
+ };
53
+ },
54
+ computed: { bubbleStyle() {
55
+ let { x: e, y: t } = this.pos;
56
+ return {
57
+ left: `${e}px`,
58
+ top: `${t}px`,
59
+ "pointer-events": "auto"
60
+ };
61
+ } },
62
+ mounted() {
63
+ this.$nextTick(() => this.calcPos()), window.addEventListener("resize", this.onResize);
64
+ },
65
+ beforeUnmount() {
66
+ window.removeEventListener("resize", this.onResize);
67
+ },
68
+ methods: {
69
+ hide() {
70
+ this.$emit("hide");
71
+ },
72
+ calcPos() {
73
+ let e = this.getAnchorEl();
74
+ if (!e) return;
75
+ let { anchorDir: t } = this.resolvedProps;
76
+ this.pos = this.getAnchorPoint(e, t === "auto" ? "middle" : t), this.calcDirAlign(), t === "auto" && (this.pos = this.getAnchorPoint(e, this.actualDir)), this.ready = !0, this.$nextTick(() => this.$emit("ready"));
77
+ },
78
+ calcDirAlign() {
79
+ let e = this.pos.y < window.innerHeight * .5, t = this.pos.x < window.innerWidth * .5, { align: n, dir: r } = this.resolvedProps;
80
+ this.actualAlign = n === "auto" ? [
81
+ "top",
82
+ "bottom",
83
+ "v"
84
+ ].includes(r) ? t ? "start" : "end" : e ? "start" : "end" : n, this.actualDir = r === "v" ? e ? "bottom" : "top" : r === "h" ? t ? "right" : "left" : r;
85
+ },
86
+ getAnchorEl() {
87
+ if (this.resolvedProps.anchorEl) return this.resolvedProps.anchorEl;
88
+ if (this.resolvedProps.anchorRef) {
89
+ let e = this.findRef(this.$parent, this.resolvedProps.anchorRef);
90
+ if (e) return e;
91
+ }
92
+ return this.$el.parentElement;
93
+ },
94
+ findRef(e, t) {
95
+ if (!e) return null;
96
+ let n = e.$refs[t];
97
+ if (n) {
98
+ let e = n.$el ?? n;
99
+ if (e instanceof HTMLElement) return e;
100
+ }
101
+ return e.$parent ? this.findRef(e.$parent, t) : null;
102
+ },
103
+ getAnchorPoint(e, t) {
104
+ let { top: n, left: r, width: i, height: a } = e.getBoundingClientRect();
105
+ switch (t) {
106
+ case "left": return {
107
+ x: r,
108
+ y: n + a * .5
109
+ };
110
+ case "right": return {
111
+ x: r + i,
112
+ y: n + a * .5
113
+ };
114
+ case "top": return {
115
+ x: r + i * .5,
116
+ y: n
117
+ };
118
+ case "bottom": return {
119
+ x: r + i * .5,
120
+ y: n + a
121
+ };
122
+ default: return {
123
+ x: r + i * .5,
124
+ y: n + a * .5
125
+ };
126
+ }
127
+ },
128
+ onResize() {
129
+ this.calcPos();
130
+ }
131
+ }
132
+ };
133
+ function f(e, t, n, d, f, p) {
134
+ let m = c("Bubble"), h = c("ModalOverlay");
135
+ return o(), r(h, {
136
+ overlayEnabled: e.resolvedProps.overlayEnabled,
137
+ overlayShown: e.resolvedProps.overlayShown,
138
+ onHide: p.hide
139
+ }, {
140
+ default: l(() => [f.ready ? (o(), r(m, {
141
+ key: 0,
142
+ dir: f.actualDir,
143
+ align: f.actualAlign,
144
+ style: a(p.bubbleStyle),
145
+ arrowShown: e.resolvedProps.arrowShown,
146
+ onMouseenter: t[0] ||= (t) => e.$emit("mouseenter"),
147
+ onMouseleave: t[1] ||= (t) => e.$emit("mouseleave"),
148
+ onClick: t[2] ||= u(() => {}, ["stop"])
149
+ }, {
150
+ default: l(() => [s(e.$slots, "default")]),
151
+ _: 3
152
+ }, 8, [
153
+ "dir",
154
+ "align",
155
+ "style",
156
+ "arrowShown"
157
+ ])) : i("", !0)]),
158
+ _: 3
159
+ }, 8, [
160
+ "overlayEnabled",
161
+ "overlayShown",
162
+ "onHide"
163
+ ]);
164
+ }
165
+ var p = /*#__PURE__*/ n(d, [["render", f]]);
166
+ export { p as default };
@@ -1,4 +1,11 @@
1
- declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
1
+ import { default as ModalOverlay } from './ModalOverlay.vue';
2
+ declare const _default: typeof __VLS_export;
3
+ export default _default;
4
+ export type __VLS_LocalComponents = typeof __VLS_componentsOption;
5
+ export type __VLS_GlobalComponents = import('vue').GlobalComponents;
6
+ export type __VLS_LocalDirectives = {};
7
+ export type __VLS_Slots = ReturnType<typeof __VLS_template>["__VLS_Slots"];
8
+ declare const __VLS_export: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
2
9
  dir: {
3
10
  type: StringConstructor;
4
11
  default: string;
@@ -10,6 +17,9 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
10
17
  anchorRef: {
11
18
  type: StringConstructor;
12
19
  };
20
+ anchorEl: {
21
+ default: null;
22
+ };
13
23
  anchorDir: {
14
24
  type: StringConstructor;
15
25
  default: string;
@@ -72,6 +82,9 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
72
82
  anchorRef: {
73
83
  type: StringConstructor;
74
84
  };
85
+ anchorEl: {
86
+ default: null;
87
+ };
75
88
  anchorDir: {
76
89
  type: StringConstructor;
77
90
  default: string;
@@ -99,6 +112,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
99
112
  arrowShown: boolean;
100
113
  overlayEnabled: boolean;
101
114
  overlayShown: boolean;
115
+ anchorEl: null;
102
116
  anchorDir: string;
103
117
  }, {}, {
104
118
  ModalOverlay: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
@@ -138,5 +152,12 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
138
152
  overlayShown: boolean;
139
153
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
140
154
  }, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
141
- export default _default;
155
+ declare namespace __VLS_componentsOption {
156
+ export { ModalOverlay };
157
+ }
158
+ declare function __VLS_template(): {
159
+ __VLS_Slots: {
160
+ default?: (props: {}) => any;
161
+ };
162
+ };
142
163
  //# sourceMappingURL=ContextPopup.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ContextPopup.vue.d.ts","sourceRoot":"","sources":["../../src/components/ContextPopup.vue"],"names":[],"mappings":"AAkBA;"}
1
+ {"version":3,"file":"ContextPopup.vue.d.ts","sourceRoot":"","sources":["../../src/components/ContextPopup.vue"],"names":[],"mappings":"AAkBA;wBAoL0B,OAAO,YAAY;;oCAK/B,OAAO,sBAAsB;qCAC7B,OAAO,KAAK,EAAE,gBAAgB;oCAG9B,EAAE;0BA6FF,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC,aAAa,CAAC;AAE9D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qEAqJG;;;;AAjPH;;kBAmFc,CAAC,KAAK,IAAiB,KAAK,GAAG;;EAM5C;yBAvGwB,oBAAoB"}
@@ -0,0 +1 @@
1
+ @layer nightshade;@layer nightshade-components{.Filler[data-v-c8d0c3a1]{--Filler-border:var(--border-base);flex:1;min-width:0;min-height:0}.Filler-dotted[data-v-c8d0c3a1]{border-bottom:2px dotted var(--Filler-border)}.Filler-dashed[data-v-c8d0c3a1]{border-bottom:2px dashed var(--Filler-border)}.Filler-solid[data-v-c8d0c3a1]{border-bottom:2px solid var(--Filler-border)}}
@@ -0,0 +1,18 @@
1
+ import './Filler.css';
2
+ import { nightshadeMixin as e } from "../helpers/props.js";
3
+ /* empty css */
4
+ import t from "../_virtual/_plugin-vue_export-helper.js";
5
+ import { createElementBlock as n, normalizeClass as r, openBlock as i } from "vue";
6
+ // src/components/Filler.vue
7
+ var a = {
8
+ mixins: [e],
9
+ props: { fill: {
10
+ type: String,
11
+ default: "none"
12
+ } }
13
+ };
14
+ function o(e, t, a, o, s, c) {
15
+ return i(), n("div", { class: r(["Filler", [`Filler-${e.resolvedProps.fill}`]]) }, null, 2);
16
+ }
17
+ var s = /*#__PURE__*/ t(a, [["render", o], ["__scopeId", "data-v-c8d0c3a1"]]);
18
+ export { s as default };
@@ -1,4 +1,9 @@
1
- declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
1
+ declare const _default: typeof __VLS_export;
2
+ export default _default;
3
+ export type __VLS_LocalComponents = {};
4
+ export type __VLS_GlobalComponents = import('vue').GlobalComponents;
5
+ export type __VLS_LocalDirectives = {};
6
+ declare const __VLS_export: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
2
7
  fill: {
3
8
  type: StringConstructor;
4
9
  default: string;
@@ -20,5 +25,4 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
20
25
  }>> & Readonly<{}>, {
21
26
  fill: string;
22
27
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
23
- export default _default;
24
28
  //# sourceMappingURL=Filler.vue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Filler.vue.d.ts","sourceRoot":"","sources":["../../src/components/Filler.vue"],"names":[],"mappings":"AAOA;"}
1
+ {"version":3,"file":"Filler.vue.d.ts","sourceRoot":"","sources":["../../src/components/Filler.vue"],"names":[],"mappings":"AAOA;wBAuD0B,OAAO,YAAY;;oCAE/B,EAAE;qCACF,OAAO,KAAK,EAAE,gBAAgB;oCAG9B,EAAE;AAsBhB;;;;;;;;;;;;;;;;;;;;;6EAQG"}
@@ -0,0 +1 @@
1
+ @layer nightshade;@layer nightshade-components{.HGroup[data-v-304c79b0]{--HGroup-gap:var(--sp1);gap:var(--HGroup-gap);flex-flow:row;display:flex}.HGroup-align-stretch[data-v-304c79b0]{align-items:stretch}.HGroup-align-baseline[data-v-304c79b0]{align-items:baseline}.HGroup-align-center[data-v-304c79b0]{align-items:center}.HGroup-align-start[data-v-304c79b0]{align-items:flex-start}.HGroup-align-end[data-v-304c79b0]{align-items:flex-end}.HGroup-justify-center[data-v-304c79b0]{justify-content:center}.HGroup-justify-start[data-v-304c79b0]{justify-content:flex-start}.HGroup-justify-end[data-v-304c79b0]{justify-content:flex-end}.HGroup-justify-space-around[data-v-304c79b0]{justify-content:space-around}.HGroup-justify-space-between[data-v-304c79b0]{justify-content:space-between}.HGroup-justify-space-evenly[data-v-304c79b0]{justify-content:space-evenly}.HGroup-wrap[data-v-304c79b0]{flex-wrap:wrap}}
@@ -0,0 +1,44 @@
1
+ import './HGroup.css';
2
+ import { nightshadeMixin as e } from "../helpers/props.js";
3
+ /* empty css */
4
+ import t from "../_virtual/_plugin-vue_export-helper.js";
5
+ import { createBlock as n, normalizeClass as r, normalizeStyle as i, openBlock as a, renderSlot as o, resolveDynamicComponent as s, withCtx as c } from "vue";
6
+ // src/components/HGroup.vue
7
+ var l = {
8
+ mixins: [e],
9
+ props: {
10
+ tagName: {
11
+ type: String,
12
+ default: "div"
13
+ },
14
+ align: {
15
+ type: String,
16
+ default: "center"
17
+ },
18
+ justify: { type: String },
19
+ gap: { type: [String, Number] },
20
+ wrap: {
21
+ type: Boolean,
22
+ default: !1
23
+ }
24
+ },
25
+ computed: { gapStyle() {
26
+ let { gap: e } = this.resolvedProps;
27
+ return e == null ? {} : { "--HGroup-gap": String(e) === "0" ? "0px" : `var(--sp${e})` };
28
+ } }
29
+ };
30
+ function u(e, t, l, u, d, f) {
31
+ return a(), n(s(e.resolvedProps.tagName), {
32
+ class: r(["HGroup", [
33
+ `HGroup-align-${e.resolvedProps.align}`,
34
+ e.resolvedProps.justify && `HGroup-justify-${e.resolvedProps.justify}`,
35
+ { "HGroup-wrap": e.resolvedProps.wrap }
36
+ ]]),
37
+ style: i(f.gapStyle)
38
+ }, {
39
+ default: c(() => [o(e.$slots, "default", {}, void 0, !0)]),
40
+ _: 3
41
+ }, 8, ["style", "class"]);
42
+ }
43
+ var d = /*#__PURE__*/ t(l, [["render", u], ["__scopeId", "data-v-304c79b0"]]);
44
+ export { d as default };