@bobbykim/manguito-theme 0.17.0 → 0.19.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 (66) hide show
  1. package/LICENSE.md +1 -1
  2. package/README.md +3 -2
  3. package/dist/core.cjs +2 -0
  4. package/dist/core.d.ts +676 -0
  5. package/dist/core.js +2088 -0
  6. package/dist/mcl-theme.cjs +1 -0
  7. package/dist/mcl-theme.d.ts +12 -0
  8. package/dist/mcl-theme.js +608 -0
  9. package/package.json +28 -7
  10. package/CHANGELOG.md +0 -137
  11. package/index.d.ts +0 -13
  12. package/index.js +0 -18
  13. package/index.ts +0 -29
  14. package/lib/collapse/Collapse.vue +0 -126
  15. package/lib/collapse/Collapse.vue.d.ts +0 -55
  16. package/lib/composables/index.d.ts +0 -1
  17. package/lib/composables/index.js +0 -1
  18. package/lib/composables/index.ts +0 -1
  19. package/lib/composables/observeVisible.d.ts +0 -1
  20. package/lib/composables/observeVisible.js +0 -24
  21. package/lib/composables/observeVisible.ts +0 -24
  22. package/lib/directives/index.d.ts +0 -6
  23. package/lib/directives/index.js +0 -186
  24. package/lib/directives/index.ts +0 -211
  25. package/lib/directives/index.types.d.ts +0 -14
  26. package/lib/directives/index.types.js +0 -1
  27. package/lib/directives/index.types.ts +0 -15
  28. package/lib/dropdown/DropdownContainer.vue +0 -50
  29. package/lib/dropdown/DropdownContainer.vue.d.ts +0 -19
  30. package/lib/dropdown/DropdownContent.vue +0 -69
  31. package/lib/dropdown/DropdownContent.vue.d.ts +0 -42
  32. package/lib/dropdown/index.types.d.ts +0 -4
  33. package/lib/dropdown/index.types.js +0 -1
  34. package/lib/dropdown/index.types.ts +0 -4
  35. package/lib/header/HeaderHorizontal.vue +0 -158
  36. package/lib/header/HeaderHorizontal.vue.d.ts +0 -84
  37. package/lib/header/HeaderVertical.vue +0 -116
  38. package/lib/header/HeaderVertical.vue.d.ts +0 -70
  39. package/lib/header/NavDrawer.vue +0 -121
  40. package/lib/header/NavDrawer.vue.d.ts +0 -43
  41. package/lib/header/index.types.d.ts +0 -1
  42. package/lib/header/index.types.js +0 -1
  43. package/lib/header/index.types.ts +0 -1
  44. package/lib/modal/Modal.vue +0 -227
  45. package/lib/modal/Modal.vue.d.ts +0 -108
  46. package/lib/sidebar/Sidebar.vue +0 -256
  47. package/lib/sidebar/Sidebar.vue.d.ts +0 -113
  48. package/lib/theme/generateClass.d.ts +0 -2
  49. package/lib/theme/generateClass.js +0 -18
  50. package/lib/theme/generateClass.ts +0 -25
  51. package/lib/theme/index.d.ts +0 -95
  52. package/lib/theme/index.js +0 -642
  53. package/lib/theme/index.ts +0 -676
  54. package/lib/theme/theme.d.ts +0 -89
  55. package/lib/theme/theme.js +0 -851
  56. package/lib/theme/theme.ts +0 -893
  57. package/lib/theme/theme.types.d.ts +0 -21
  58. package/lib/theme/theme.types.js +0 -1
  59. package/lib/theme/theme.types.ts +0 -68
  60. package/lib/tooltip/index.d.ts +0 -62
  61. package/lib/tooltip/index.js +0 -71
  62. package/lib/tooltip/index.ts +0 -76
  63. package/themeVariables.cjs +0 -607
  64. package/tsconfig.json +0 -5
  65. package/tsconfig.ts.json +0 -9
  66. package/tsconfig.vue.json +0 -9
package/package.json CHANGED
@@ -1,24 +1,45 @@
1
1
  {
2
2
  "name": "@bobbykim/manguito-theme",
3
- "version": "0.17.0",
3
+ "version": "0.19.0",
4
4
  "description": "main theme file for manguito components library. Other MCL components will need to import this file to run.",
5
5
  "type": "module",
6
- "main": "index.ts",
7
6
  "publishConfig": {
8
7
  "access": "public"
9
8
  },
9
+ "files": [
10
+ "dist"
11
+ ],
12
+ "main": "./dist/core.cjs",
13
+ "module": "./dist/core.js",
14
+ "types": "./dist/core.d.ts",
15
+ "exports": {
16
+ ".": {
17
+ "import": "./dist/core.js",
18
+ "require": "./dist/core.cjs",
19
+ "types": "./dist/core.d.ts"
20
+ },
21
+ "./mcl-theme": {
22
+ "import": "./dist/mcl-theme.js",
23
+ "require": "./dist/mcl-theme.cjs",
24
+ "types": "./dist/mcl-theme.d.ts"
25
+ }
26
+ },
10
27
  "scripts": {
11
- "build": "vue-tsc --project tsconfig.vue.json && tsc --project tsconfig.ts.json"
28
+ "build": "vite build"
12
29
  },
13
30
  "dependencies": {
14
31
  "@vueuse/core": "^10.8.0",
15
32
  "vue": "^3.3.10"
16
33
  },
17
34
  "devDependencies": {
18
- "autoprefixer": "^10.4.16",
19
- "postcss": "^8.4.32",
35
+ "@vitejs/plugin-vue": "^4.5.2",
20
36
  "sass": "^1.69.5",
21
- "tailwindcss": "^3.3.6"
37
+ "tailwindcss": "^3.3.6",
38
+ "typescript": "^5.3.3",
39
+ "vite": "^4.5.1",
40
+ "vite-plugin-css-injected-by-js": "^3.5.0",
41
+ "vite-plugin-dts": "^3.8.3",
42
+ "vue-tsc": "^1.8.25"
22
43
  },
23
44
  "author": {
24
45
  "name": "Bobby Kim",
@@ -30,5 +51,5 @@
30
51
  "url": "https://github.com/bobbykim89/manguito-component-library.git"
31
52
  },
32
53
  "license": "MIT",
33
- "gitHead": "f4be01699f747aba1f831a1f796f8e41e6fcd676"
54
+ "gitHead": "b66ad8b5fabf32c0814726f0847ce86399b4115b"
34
55
  }
package/CHANGELOG.md DELETED
@@ -1,137 +0,0 @@
1
- # Change Log
2
-
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- # [0.17.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.15.0...@bobbykim/manguito-theme@0.17.0) (2024-03-24)
7
-
8
-
9
- ### Features
10
-
11
- * build and release ([a372086](https://github.com/bobbykim89/manguito-component-library/commit/a3720861fb40dd6ec1d0e3dda1f06e2479967432))
12
- * code refactor ([8a025e7](https://github.com/bobbykim89/manguito-component-library/commit/8a025e7cf870ff3dd0cb35878a08793e99ec5cef))
13
- * **components/*:** prepublish build ([c8eb95a](https://github.com/bobbykim89/manguito-component-library/commit/c8eb95a0ede6727bf183d2e9ad634ae64af1411d))
14
- * **manguito-theme:** add header-vertical component ([05c339d](https://github.com/bobbykim89/manguito-component-library/commit/05c339d77cdded35d2e45a5c22c3833329e41532))
15
- * **manguito-theme:** add new base component header-horizontal ([d3826ee](https://github.com/bobbykim89/manguito-component-library/commit/d3826ee1da15ea0edd2fa7f959269704f22008b3))
16
- * **manguito-theme:** code refactor ([d310131](https://github.com/bobbykim89/manguito-component-library/commit/d31013189fa5e1c4f8085de63a08ee2932652f55))
17
- * **mcl-header-a:** wip) update mcl-header-a ([344a13f](https://github.com/bobbykim89/manguito-component-library/commit/344a13f3cd25c6b02fc99866f19ae65bc89d9ec5))
18
- * **mcl-header-b:** add mobile layout for mcl-header-b ([ca961ec](https://github.com/bobbykim89/manguito-component-library/commit/ca961ecbaecab1d2e879cb62e905e713878539c0))
19
- * **mcl-header-b:** add more layouts for desktop screen ([bfd1c7e](https://github.com/bobbykim89/manguito-component-library/commit/bfd1c7e8ed3d9b839bea0dd1a7c3b5740a345c41))
20
- * **mcl-header-b:** fix minor issues with mcl closing collapses in menu item click, update text color of menu items ([1ecfcf3](https://github.com/bobbykim89/manguito-component-library/commit/1ecfcf3ec474e6a6097a34bb9861cbb680280530))
21
- * **mcl-header-b:** wip) adding story file for mcl-header-b ([2a80675](https://github.com/bobbykim89/manguito-component-library/commit/2a8067553df9a138398aef2a898ebdf3b4a9a268))
22
- * **mcl-header:** move deprecated items to deprecated folder in root dir, update configs, init mcl-header-b component ([19aa842](https://github.com/bobbykim89/manguito-component-library/commit/19aa842faa7f1594f7be030b97d5093014efe7cb))
23
- * tsconfig update, slots and emits update ([c30ff80](https://github.com/bobbykim89/manguito-component-library/commit/c30ff804c961d205ac097e20cd51285a15ca8966))
24
-
25
-
26
-
27
-
28
-
29
- # [0.16.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.15.0...@bobbykim/manguito-theme@0.16.0) (2024-03-21)
30
-
31
-
32
- ### Features
33
-
34
- * code refactor ([8a025e7](https://github.com/bobbykim89/manguito-component-library/commit/8a025e7cf870ff3dd0cb35878a08793e99ec5cef))
35
- * **manguito-theme:** add header-vertical component ([05c339d](https://github.com/bobbykim89/manguito-component-library/commit/05c339d77cdded35d2e45a5c22c3833329e41532))
36
- * **manguito-theme:** add new base component header-horizontal ([d3826ee](https://github.com/bobbykim89/manguito-component-library/commit/d3826ee1da15ea0edd2fa7f959269704f22008b3))
37
- * **mcl-header-a:** wip) update mcl-header-a ([344a13f](https://github.com/bobbykim89/manguito-component-library/commit/344a13f3cd25c6b02fc99866f19ae65bc89d9ec5))
38
- * **mcl-header-b:** add mobile layout for mcl-header-b ([ca961ec](https://github.com/bobbykim89/manguito-component-library/commit/ca961ecbaecab1d2e879cb62e905e713878539c0))
39
- * **mcl-header-b:** add more layouts for desktop screen ([bfd1c7e](https://github.com/bobbykim89/manguito-component-library/commit/bfd1c7e8ed3d9b839bea0dd1a7c3b5740a345c41))
40
- * **mcl-header-b:** fix minor issues with mcl closing collapses in menu item click, update text color of menu items ([1ecfcf3](https://github.com/bobbykim89/manguito-component-library/commit/1ecfcf3ec474e6a6097a34bb9861cbb680280530))
41
- * **mcl-header-b:** wip) adding story file for mcl-header-b ([2a80675](https://github.com/bobbykim89/manguito-component-library/commit/2a8067553df9a138398aef2a898ebdf3b4a9a268))
42
- * **mcl-header:** move deprecated items to deprecated folder in root dir, update configs, init mcl-header-b component ([19aa842](https://github.com/bobbykim89/manguito-component-library/commit/19aa842faa7f1594f7be030b97d5093014efe7cb))
43
- * tsconfig update, slots and emits update ([c30ff80](https://github.com/bobbykim89/manguito-component-library/commit/c30ff804c961d205ac097e20cd51285a15ca8966))
44
-
45
-
46
-
47
-
48
-
49
- # [0.15.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.14.0...@bobbykim/manguito-theme@0.15.0) (2024-02-27)
50
-
51
-
52
- ### Features
53
-
54
- * **/components/**/README.md,/deprecated:** update readme files, move deprecated packages to deprecated folder ([c0f8f7d](https://github.com/bobbykim89/manguito-component-library/commit/c0f8f7df158b8fcd99b4e3d191e02e3c8a9c144d))
55
-
56
-
57
-
58
-
59
-
60
- # [0.14.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.13.0...@bobbykim/manguito-theme@0.14.0) (2024-02-27)
61
-
62
-
63
- ### Features
64
-
65
- * **components/*:** run package:build ([fcc2d09](https://github.com/bobbykim89/manguito-component-library/commit/fcc2d0953d77ecaa317be27eb212c927dec33b17))
66
- * **manguito-theme,mcl-cards,mcl-header,mcl-footer,mcl-carousel:** add vueuse as one of dependencies, update code to make them ssr friendly ([119a327](https://github.com/bobbykim89/manguito-component-library/commit/119a327adf1ca9866e6ac063bce5acd4790db612))
67
- * **mcl-collapse:** add mcl-collapse component library and add story for mcl-collapse-a ([397b63e](https://github.com/bobbykim89/manguito-component-library/commit/397b63e00b83801bdf1cd2c6710d0ba876c6bf87))
68
- * **stories/*:** ran package:build to build type declaration, move deprecated story files into deprecated folder ([ffc487d](https://github.com/bobbykim89/manguito-component-library/commit/ffc487dbcc093be7a3ccfeae98c5e10e8372a0e3))
69
- * **stories:** add basic addons, add stories for theme and base component ([841d8db](https://github.com/bobbykim89/manguito-component-library/commit/841d8db015d3d861f567ae3d19cf0033b28bac7c))
70
-
71
-
72
-
73
-
74
-
75
- # [0.13.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.12.0...@bobbykim/manguito-theme@0.13.0) (2023-12-06)
76
-
77
-
78
- ### Features
79
-
80
- * **tsconfig,-card-delta:** card-delta bug fix, update tsconfig ([4c469b9](https://github.com/bobbykim89/manguito-component-library/commit/4c469b933632e3e729f6b75f7e808c89c090d463))
81
- * **tsconfig:** install dependencies and update tsconfig to not generate source map ([0bd4d4c](https://github.com/bobbykim89/manguito-component-library/commit/0bd4d4c78503ef156dbb3d49aa3e67e7e0e68289))
82
-
83
-
84
-
85
-
86
-
87
- # [0.12.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.11.0...@bobbykim/manguito-theme@0.12.0) (2023-12-02)
88
-
89
-
90
- ### Features
91
-
92
- * **manguito-theme,accordion-alpha,accordion-beta,nav-alpha:** change tsconfig settings ([055e6d8](https://github.com/bobbykim89/manguito-component-library/commit/055e6d8781705fcc144769da90470eb0d5e36612))
93
-
94
-
95
-
96
-
97
-
98
- # [0.11.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.10.0...@bobbykim/manguito-theme@0.11.0) (2023-12-02)
99
-
100
-
101
- ### Features
102
-
103
- * **manguito-theme:** update import path ([c6c69fa](https://github.com/bobbykim89/manguito-component-library/commit/c6c69fa416e6ff7f388d97f8663a8e77b2e806d3))
104
-
105
-
106
-
107
-
108
-
109
- # [0.10.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.9.0...@bobbykim/manguito-theme@0.10.0) (2023-12-01)
110
-
111
-
112
- ### Features
113
-
114
- * **tsconfig:** update tsconfig file and some of import paths ([c7caaa3](https://github.com/bobbykim89/manguito-component-library/commit/c7caaa3101a5d57d0e799568f1c4f5cbebececc3))
115
-
116
-
117
-
118
-
119
-
120
- # [0.9.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.8.0...@bobbykim/manguito-theme@0.9.0) (2023-12-01)
121
-
122
-
123
- ### Features
124
-
125
- * **components:** target version update ([fe78575](https://github.com/bobbykim89/manguito-component-library/commit/fe78575f5e82bb854333672c3853956e9e930044))
126
-
127
-
128
-
129
-
130
-
131
- # [0.8.0](https://github.com/bobbykim89/manguito-component-library/compare/@bobbykim/manguito-theme@0.7.0...@bobbykim/manguito-theme@0.8.0) (2023-12-01)
132
-
133
-
134
- ### Features
135
-
136
- * prerelease run build ([f7a852c](https://github.com/bobbykim89/manguito-component-library/commit/f7a852c9bf12b77481bf5d2f1602e50367d834f8))
137
- * **tsconfig.json,tsconfig.vue.json:** update tsconfig ([0f21861](https://github.com/bobbykim89/manguito-component-library/commit/0f2186167342314f5d218e789a68c03cf6faa8ff))
package/index.d.ts DELETED
@@ -1,13 +0,0 @@
1
- import { generateClass } from './lib/theme/generateClass';
2
- import Collapse from './lib/collapse/Collapse.vue';
3
- import DropdownContainer from './lib/dropdown/DropdownContainer.vue';
4
- import DropdownContent from './lib/dropdown/DropdownContent.vue';
5
- import HeaderHorizontal from './lib/header/HeaderHorizontal.vue';
6
- import HeaderVertical from './lib/header/HeaderVertical.vue';
7
- import Modal from './lib/modal/Modal.vue';
8
- import Sidebar from './lib/sidebar/Sidebar.vue';
9
- export * from './lib/directives';
10
- export * from './lib/header/index.types';
11
- export * from './lib/theme/theme.types';
12
- export { Collapse, DropdownContainer, DropdownContent, HeaderHorizontal, HeaderVertical, Modal, Sidebar, };
13
- export default generateClass;
package/index.js DELETED
@@ -1,18 +0,0 @@
1
- // generate class function
2
- import { generateClass } from './lib/theme/generateClass';
3
- // base components
4
- import Collapse from './lib/collapse/Collapse.vue';
5
- import DropdownContainer from './lib/dropdown/DropdownContainer.vue';
6
- import DropdownContent from './lib/dropdown/DropdownContent.vue';
7
- import HeaderHorizontal from './lib/header/HeaderHorizontal.vue';
8
- import HeaderVertical from './lib/header/HeaderVertical.vue';
9
- import Modal from './lib/modal/Modal.vue';
10
- import Sidebar from './lib/sidebar/Sidebar.vue';
11
- // directives
12
- export * from './lib/directives';
13
- // types
14
- export * from './lib/header/index.types';
15
- export * from './lib/theme/theme.types';
16
- // export components
17
- export { Collapse, DropdownContainer, DropdownContent, HeaderHorizontal, HeaderVertical, Modal, Sidebar, };
18
- export default generateClass;
package/index.ts DELETED
@@ -1,29 +0,0 @@
1
- // generate class function
2
- import { generateClass } from './lib/theme/generateClass'
3
- // base components
4
- import Collapse from './lib/collapse/Collapse.vue'
5
- import DropdownContainer from './lib/dropdown/DropdownContainer.vue'
6
- import DropdownContent from './lib/dropdown/DropdownContent.vue'
7
- import HeaderHorizontal from './lib/header/HeaderHorizontal.vue'
8
- import HeaderVertical from './lib/header/HeaderVertical.vue'
9
- import Modal from './lib/modal/Modal.vue'
10
- import Sidebar from './lib/sidebar/Sidebar.vue'
11
-
12
- // directives
13
- export * from './lib/directives'
14
- // types
15
- export * from './lib/header/index.types'
16
- export * from './lib/theme/theme.types'
17
-
18
- // export components
19
- export {
20
- Collapse,
21
- DropdownContainer,
22
- DropdownContent,
23
- HeaderHorizontal,
24
- HeaderVertical,
25
- Modal,
26
- Sidebar,
27
- }
28
-
29
- export default generateClass
@@ -1,126 +0,0 @@
1
- <script setup lang="ts">
2
- import { Transition, onBeforeUnmount, onMounted, ref, watch } from 'vue'
3
- import { observeVisibleAttr } from '../composables'
4
-
5
- const props = withDefaults(
6
- defineProps<{
7
- accordion?: string
8
- className?: string
9
- visible?: boolean
10
- }>(),
11
- {
12
- className: '',
13
- visible: false,
14
- }
15
- )
16
- const slots = defineSlots<{
17
- default: any
18
- }>()
19
- const emit = defineEmits<{
20
- (e: 'open', visible: boolean): void
21
- (e: 'close', visible: boolean): void
22
- }>()
23
- const collapseRef = ref<HTMLElement | undefined>()
24
- const toggle = ref<boolean>(props.visible)
25
-
26
- const toggleCollapse = (): void => {
27
- toggle.value = !toggle.value
28
- }
29
- const openCollapse = (): void => {
30
- toggle.value = true
31
- }
32
- const closeCollapse = (): void => {
33
- toggle.value = false
34
- }
35
- const emitOpenEvent = () => {
36
- emit('open', true)
37
- }
38
- const emitCloseEvent = () => {
39
- emit('close', false)
40
- }
41
-
42
- /**
43
- * @TransitionFunctions
44
- * @param {HTMLElement} el - passed any since transition handlers don't accept HTMLElement (accepts Element)
45
- */
46
- const onEnter = (el: any) => {
47
- el.style.height = 'auto'
48
- el.style.opacity = '0'
49
- const endWidth = getComputedStyle(el).height
50
- el.style.height = '0px'
51
- el.offsetHeight // force repaint
52
- el.style.height = endWidth
53
- el.style.opacity = '1'
54
- }
55
- const onAfterEnter = (el: any) => {
56
- el.style.height = 'auto'
57
- el.style.opacity = '1'
58
- }
59
- const onLeave = (el: any) => {
60
- el.style.height = getComputedStyle(el).height
61
- el.offsetHeight // force repaint
62
- el.style.height = '0px'
63
- el.style.opacity = '0'
64
- }
65
-
66
- // set nutation observer watching `visible` attribute in element
67
- const handleVisibility = (visible: boolean = false) => {
68
- toggle.value = visible
69
- }
70
- const observer = observeVisibleAttr(handleVisibility)
71
-
72
- watch(
73
- () => props.visible,
74
- (newValue) => {
75
- toggle.value = newValue
76
- }
77
- )
78
- watch(toggle, (newValue) => {
79
- if (newValue === true) {
80
- emitOpenEvent()
81
- } else if (newValue === false) {
82
- emitCloseEvent()
83
- }
84
- })
85
- defineExpose({
86
- toggle: toggleCollapse,
87
- close: closeCollapse,
88
- open: openCollapse,
89
- })
90
- onMounted(() => {
91
- if (collapseRef.value) {
92
- observer.observe(collapseRef.value, { attributes: true })
93
- }
94
- })
95
- onBeforeUnmount(() => {
96
- observer.disconnect()
97
- })
98
- </script>
99
-
100
- <template>
101
- <div :accordion="accordion" :visible="toggle" ref="collapseRef">
102
- <transition
103
- name="collapse"
104
- tag="div"
105
- @enter="onEnter"
106
- @after-enter="onAfterEnter"
107
- @leave="onLeave"
108
- class="overflow-y-clip"
109
- >
110
- <div v-show="toggle">
111
- <div :class="[className]">
112
- <slot />
113
- </div>
114
- </div>
115
- </transition>
116
- </div>
117
- </template>
118
-
119
- <style scoped lang="scss">
120
- .collapse-enter-active,
121
- .collapse-leave-active {
122
- transition-property: height, opacity;
123
- transition-duration: 500ms;
124
- transition-timing-function: ease;
125
- }
126
- </style>
@@ -1,55 +0,0 @@
1
- declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
2
- accordion?: string | undefined;
3
- className?: string | undefined;
4
- visible?: boolean | undefined;
5
- }>, {
6
- className: string;
7
- visible: boolean;
8
- }>, {
9
- toggle: () => void;
10
- close: () => void;
11
- open: () => void;
12
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
13
- open: (visible: boolean) => void;
14
- close: (visible: boolean) => void;
15
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
16
- accordion?: string | undefined;
17
- className?: string | undefined;
18
- visible?: boolean | undefined;
19
- }>, {
20
- className: string;
21
- visible: boolean;
22
- }>>> & {
23
- onOpen?: ((visible: boolean) => any) | undefined;
24
- onClose?: ((visible: boolean) => any) | undefined;
25
- }, {
26
- visible: boolean;
27
- className: string;
28
- }, {}>, Readonly<{
29
- default: any;
30
- }> & {
31
- default: any;
32
- }>;
33
- export default _default;
34
- type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
35
- type __VLS_TypePropsToRuntimeProps<T> = {
36
- [K in keyof T]-?: {} extends Pick<T, K> ? {
37
- type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
38
- } : {
39
- type: import('vue').PropType<T[K]>;
40
- required: true;
41
- };
42
- };
43
- type __VLS_WithDefaults<P, D> = {
44
- [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
45
- default: D[K];
46
- }> : P[K];
47
- };
48
- type __VLS_Prettify<T> = {
49
- [K in keyof T]: T[K];
50
- } & {};
51
- type __VLS_WithTemplateSlots<T, S> = T & {
52
- new (): {
53
- $slots: S;
54
- };
55
- };
@@ -1 +0,0 @@
1
- export * from './observeVisible.js';
@@ -1 +0,0 @@
1
- export * from './observeVisible.js';
@@ -1 +0,0 @@
1
- export * from './observeVisible.js'
@@ -1 +0,0 @@
1
- export declare const observeVisibleAttr: (fn: (...args: any[]) => void) => MutationObserver;
@@ -1,24 +0,0 @@
1
- export const observeVisibleAttr = (fn) => {
2
- const observer = new MutationObserver((mutations) => {
3
- let changed = false;
4
- for (let i = 0; i < mutations.length && !changed; i++) {
5
- const mutation = mutations[i];
6
- const mutationType = mutation.type;
7
- const mutationAttribute = mutation.attributeName;
8
- const mutationTarget = mutation.target;
9
- if (mutationType === 'attributes') {
10
- changed = true;
11
- }
12
- else if (mutationAttribute === 'visible') {
13
- changed = true;
14
- }
15
- if (changed) {
16
- const visibleAttr = mutationTarget.getAttribute('visible') === 'true'
17
- ? true
18
- : false;
19
- fn(visibleAttr);
20
- }
21
- }
22
- });
23
- return observer;
24
- };
@@ -1,24 +0,0 @@
1
- export const observeVisibleAttr = (fn: (...args: any[]) => void) => {
2
- const observer = new MutationObserver((mutations) => {
3
- let changed = false
4
- for (let i = 0; i < mutations.length && !changed; i++) {
5
- const mutation = mutations[i]
6
- const mutationType = mutation.type
7
- const mutationAttribute = mutation.attributeName
8
- const mutationTarget = mutation.target
9
- if (mutationType === 'attributes') {
10
- changed = true
11
- } else if (mutationAttribute === 'visible') {
12
- changed = true
13
- }
14
- if (changed) {
15
- const visibleAttr =
16
- (mutationTarget as HTMLElement).getAttribute('visible') === 'true'
17
- ? true
18
- : false
19
- fn(visibleAttr)
20
- }
21
- }
22
- })
23
- return observer
24
- }
@@ -1,6 +0,0 @@
1
- import type { Directive } from 'vue';
2
- import type { TooltipElementType, TooltipValueType } from './index.types.js';
3
- export declare const vClickOutside: Directive;
4
- export declare const vToggle: Directive;
5
- export declare const vCollapse: Directive;
6
- export declare const vTooltip: Directive<TooltipElementType, TooltipValueType>;