daisy-ui-kit 3.0.12 → 5.0.0-pre.4
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/README.md +62 -14
- package/package.json +41 -61
- package/components/Accordion.vue +0 -29
- package/components/Alert.vue +0 -25
- package/components/Artboard.vue +0 -33
- package/components/Avatar.vue +0 -70
- package/components/AvatarGroup.vue +0 -19
- package/components/Badge.vue +0 -50
- package/components/BottomNav.vue +0 -25
- package/components/Breadcrumbs.vue +0 -7
- package/components/Button.vue +0 -111
- package/components/Card.vue +0 -30
- package/components/CardActions.vue +0 -16
- package/components/CardBody.vue +0 -16
- package/components/CardTitle.vue +0 -16
- package/components/Carousel.vue +0 -25
- package/components/CarouselItem.vue +0 -5
- package/components/Chat.vue +0 -27
- package/components/ChatBubble.vue +0 -34
- package/components/ChatFooter.vue +0 -5
- package/components/ChatHeader.vue +0 -5
- package/components/ChatImage.vue +0 -5
- package/components/Checkbox.vue +0 -55
- package/components/Code.vue +0 -92
- package/components/Collapse.vue +0 -54
- package/components/CollapseContent.vue +0 -5
- package/components/CollapseTitle.vue +0 -5
- package/components/Countdown.vue +0 -15
- package/components/CountdownTimers.vue +0 -70
- package/components/Counter.vue +0 -14
- package/components/Crumb.vue +0 -5
- package/components/Divider.vue +0 -24
- package/components/Drawer.vue +0 -45
- package/components/DrawerContent.vue +0 -17
- package/components/DrawerSide.vue +0 -18
- package/components/Dropdown.vue +0 -95
- package/components/DropdownButton.vue +0 -16
- package/components/DropdownContent.vue +0 -56
- package/components/DropdownTarget.vue +0 -14
- package/components/FileInput.vue +0 -59
- package/components/Flex.vue +0 -59
- package/components/FlexItem.vue +0 -59
- package/components/Footer.vue +0 -24
- package/components/FooterTitle.vue +0 -15
- package/components/FormControl.vue +0 -5
- package/components/Hero.vue +0 -15
- package/components/HeroContent.vue +0 -15
- package/components/HeroOverlay.vue +0 -5
- package/components/Indicator.vue +0 -13
- package/components/IndicatorItem.vue +0 -36
- package/components/Join.vue +0 -5
- package/components/Kbd.vue +0 -25
- package/components/Label.vue +0 -15
- package/components/LabelText.vue +0 -15
- package/components/LabelTextAlt.vue +0 -15
- package/components/Link.vue +0 -40
- package/components/LoadingBall.vue +0 -43
- package/components/LoadingBars.vue +0 -43
- package/components/LoadingDots.vue +0 -43
- package/components/LoadingInfinity.vue +0 -43
- package/components/LoadingRing.vue +0 -43
- package/components/LoadingSpinner.vue +0 -43
- package/components/Mask.config.ts +0 -77
- package/components/Mask.vue +0 -14
- package/components/Menu.vue +0 -35
- package/components/MenuExpand.vue +0 -79
- package/components/MenuExpandToggle.vue +0 -13
- package/components/MenuItem.vue +0 -38
- package/components/MenuTitle.vue +0 -5
- package/components/MockupBrowser.vue +0 -5
- package/components/MockupBrowserToolbar.vue +0 -5
- package/components/MockupCode.vue +0 -4
- package/components/MockupPhone.vue +0 -8
- package/components/MockupWindow.vue +0 -5
- package/components/Modal.vue +0 -48
- package/components/ModalAction.vue +0 -5
- package/components/ModalBox.vue +0 -5
- package/components/NavButton.vue +0 -20
- package/components/Navbar.vue +0 -14
- package/components/NavbarCenter.vue +0 -13
- package/components/NavbarEnd.vue +0 -13
- package/components/NavbarStart.vue +0 -13
- package/components/Progress.vue +0 -42
- package/components/Prose.vue +0 -32
- package/components/RadialProgress.vue +0 -41
- package/components/Radio.vue +0 -76
- package/components/RadioGroup.vue +0 -46
- package/components/Range.vue +0 -60
- package/components/RangeMeasure.vue +0 -83
- package/components/RangeMeasureTick.vue +0 -74
- package/components/Rating.vue +0 -167
- package/components/Select.vue +0 -100
- package/components/Stack.vue +0 -13
- package/components/Stat.vue +0 -5
- package/components/StatActions.vue +0 -5
- package/components/StatDesc.vue +0 -5
- package/components/StatFigure.vue +0 -5
- package/components/StatTitle.vue +0 -5
- package/components/StatValue.vue +0 -5
- package/components/Stats.vue +0 -5
- package/components/Step.vue +0 -36
- package/components/Steps.vue +0 -21
- package/components/Swap.vue +0 -58
- package/components/Tab.vue +0 -48
- package/components/TabContent.vue +0 -29
- package/components/Tabs.vue +0 -77
- package/components/TabsManager.vue +0 -38
- package/components/Text.vue +0 -142
- package/components/TextArea.vue +0 -64
- package/components/TextInput.vue +0 -66
- package/components/Toast.vue +0 -31
- package/components/Toggle.vue +0 -59
- package/components/Tooltip.vue +0 -47
- package/index.ts +0 -108
- package/nuxt.js +0 -22
- package/utils/-utils.ts +0 -41
- package/utils/Button.config.ts +0 -26
- package/utils/drawer-utils.ts +0 -32
- package/utils/fixtures.ts +0 -62
- package/utils/random-string.ts +0 -19
- package/utils/types.ts +0 -7
package/README.md
CHANGED
|
@@ -1,27 +1,75 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Nuxt Minimal Starter
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Look at the [Nuxt documentation](https://nuxt.com/docs/getting-started/introduction) to learn more.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Setup
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Make sure to install dependencies:
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
```bash
|
|
10
|
+
# npm
|
|
11
|
+
npm install
|
|
10
12
|
|
|
11
|
-
|
|
13
|
+
# pnpm
|
|
14
|
+
pnpm install
|
|
12
15
|
|
|
13
|
-
|
|
16
|
+
# yarn
|
|
17
|
+
yarn install
|
|
14
18
|
|
|
15
|
-
|
|
19
|
+
# bun
|
|
20
|
+
bun install
|
|
21
|
+
```
|
|
16
22
|
|
|
17
|
-
##
|
|
23
|
+
## Development Server
|
|
18
24
|
|
|
19
|
-
|
|
25
|
+
Start the development server on `http://localhost:3000`:
|
|
20
26
|
|
|
21
|
-
|
|
27
|
+
```bash
|
|
28
|
+
# npm
|
|
29
|
+
npm run dev
|
|
22
30
|
|
|
23
|
-
|
|
31
|
+
# pnpm
|
|
32
|
+
pnpm dev
|
|
24
33
|
|
|
25
|
-
|
|
34
|
+
# yarn
|
|
35
|
+
yarn dev
|
|
26
36
|
|
|
27
|
-
|
|
37
|
+
# bun
|
|
38
|
+
bun run dev
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Production
|
|
42
|
+
|
|
43
|
+
Build the application for production:
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
# npm
|
|
47
|
+
npm run build
|
|
48
|
+
|
|
49
|
+
# pnpm
|
|
50
|
+
pnpm build
|
|
51
|
+
|
|
52
|
+
# yarn
|
|
53
|
+
yarn build
|
|
54
|
+
|
|
55
|
+
# bun
|
|
56
|
+
bun run build
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Locally preview production build:
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
# npm
|
|
63
|
+
npm run preview
|
|
64
|
+
|
|
65
|
+
# pnpm
|
|
66
|
+
pnpm preview
|
|
67
|
+
|
|
68
|
+
# yarn
|
|
69
|
+
yarn preview
|
|
70
|
+
|
|
71
|
+
# bun
|
|
72
|
+
bun run preview
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Check out the [deployment documentation](https://nuxt.com/docs/getting-started/deployment) for more information.
|
package/package.json
CHANGED
|
@@ -1,27 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "daisy-ui-kit",
|
|
3
|
-
"
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
"license": "MIT",
|
|
7
|
-
"homepage": "https://daisyuikit.com",
|
|
8
|
-
"repository": {
|
|
9
|
-
"type": "git",
|
|
10
|
-
"url": "https://github.com/marshallswain/daisy-ui-kit"
|
|
11
|
-
},
|
|
12
|
-
"main": "index.ts",
|
|
3
|
+
"type": "module",
|
|
4
|
+
"version": "5.0.0-pre.4",
|
|
5
|
+
"packageManager": "pnpm@10.9.0",
|
|
13
6
|
"files": [
|
|
14
7
|
"components/*.vue",
|
|
15
|
-
"
|
|
16
|
-
"utils/*"
|
|
17
|
-
"nuxt.js"
|
|
8
|
+
"nuxt.js",
|
|
9
|
+
"utils/*"
|
|
18
10
|
],
|
|
19
11
|
"scripts": {
|
|
20
|
-
"
|
|
21
|
-
"
|
|
22
|
-
"
|
|
23
|
-
"
|
|
24
|
-
"
|
|
12
|
+
"build": "nuxt build",
|
|
13
|
+
"dev": "nuxt dev",
|
|
14
|
+
"lint": "eslint",
|
|
15
|
+
"lint:fix": "eslint --fix",
|
|
16
|
+
"generate": "nuxt generate",
|
|
17
|
+
"preview": "nuxt preview",
|
|
18
|
+
"postinstall": "nuxt prepare",
|
|
25
19
|
"publish": "git push origin --tags && git push origin",
|
|
26
20
|
"release:pre": "npm version prerelease && npm publish --tag pre",
|
|
27
21
|
"release:patch": "npm version patch && npm publish",
|
|
@@ -29,52 +23,38 @@
|
|
|
29
23
|
"release:major": "npm version major && npm publish"
|
|
30
24
|
},
|
|
31
25
|
"peerDependencies": {
|
|
32
|
-
"@vueuse/core": "^
|
|
33
|
-
"daisyui": "^
|
|
34
|
-
"prismjs": "^1.29.0"
|
|
26
|
+
"@vueuse/core": "^13.1.0",
|
|
27
|
+
"daisyui": "^5"
|
|
35
28
|
},
|
|
36
29
|
"dependencies": {
|
|
37
|
-
"@floating-ui/vue": "^1.
|
|
38
|
-
"@
|
|
39
|
-
"
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
"
|
|
30
|
+
"@floating-ui/vue": "^1.1.6",
|
|
31
|
+
"@nuxt/content": "3.4.0",
|
|
32
|
+
"@nuxt/eslint": "1.3.0",
|
|
33
|
+
"@nuxt/fonts": "0.11.1",
|
|
34
|
+
"@nuxt/icon": "1.12.0",
|
|
35
|
+
"@nuxt/image": "1.10.0",
|
|
36
|
+
"@nuxt/scripts": "0.11.6",
|
|
37
|
+
"@nuxt/test-utils": "3.17.2",
|
|
38
|
+
"@unhead/vue": "^2.0.8",
|
|
39
|
+
"@vueuse/core": "^13.1.0",
|
|
40
|
+
"@vueuse/integrations": "^13.1.0",
|
|
41
|
+
"focus-trap": "^7.6.4",
|
|
42
|
+
"nuxt": "^3.16.2",
|
|
43
|
+
"pikaday": "^1.8.2",
|
|
44
|
+
"shiki": "^3.3.0",
|
|
45
|
+
"typescript": "^5.8.3",
|
|
46
|
+
"vue": "^3.5.13",
|
|
47
|
+
"vue-router": "^4.5.0",
|
|
48
|
+
"zod": "^3.24.3"
|
|
43
49
|
},
|
|
44
50
|
"devDependencies": {
|
|
45
|
-
"@antfu/eslint-config": "^
|
|
46
|
-
"@
|
|
47
|
-
"@
|
|
48
|
-
"@
|
|
49
|
-
"@
|
|
50
|
-
"
|
|
51
|
-
"
|
|
52
|
-
"
|
|
53
|
-
"@nuxtjs/tailwindcss": "^6.8.0",
|
|
54
|
-
"@pinia/nuxt": "^0.4.11",
|
|
55
|
-
"@popperjs/core": "^2.11.8",
|
|
56
|
-
"@rovit/popper": "^3.9.0",
|
|
57
|
-
"@tailwindcss/aspect-ratio": "^0.4.2",
|
|
58
|
-
"@tailwindcss/forms": "^0.5.5",
|
|
59
|
-
"@tailwindcss/line-clamp": "^0.4.4",
|
|
60
|
-
"@tailwindcss/typography": "^0.5.9",
|
|
61
|
-
"@vueuse/core": "^10.3.0",
|
|
62
|
-
"@vueuse/nuxt": "^10.3.0",
|
|
63
|
-
"autoprefixer": "^10.4.15",
|
|
64
|
-
"cookie": "^0.5.0",
|
|
65
|
-
"daisyui": "^3.6.3",
|
|
66
|
-
"eslint": "^8.48.0",
|
|
67
|
-
"feathers-pinia": "^4.0.0",
|
|
68
|
-
"fuse.js": "^6.6.2",
|
|
69
|
-
"mobile-detect": "^1.4.5",
|
|
70
|
-
"nuxt": "^3.6.5",
|
|
71
|
-
"nuxt-icon": "^0.5.0",
|
|
72
|
-
"ohmyfetch": "^0.4.21",
|
|
73
|
-
"pinia": "^2.1.6",
|
|
74
|
-
"postcss": "^8.4.28",
|
|
75
|
-
"tailwindcss": "^3.3.3",
|
|
76
|
-
"typescript": "^5.2.2",
|
|
77
|
-
"unplugin-icons": "^0.16.5",
|
|
78
|
-
"vue": "^3.3.4"
|
|
51
|
+
"@antfu/eslint-config": "^4.12.0",
|
|
52
|
+
"@stylistic/eslint-plugin": "^4.2.0",
|
|
53
|
+
"@tailwindcss/typography": "^0.5.16",
|
|
54
|
+
"@tailwindcss/vite": "^4.1.4",
|
|
55
|
+
"@types/pikaday": "^1.7.9",
|
|
56
|
+
"daisyui": "^5.0.27",
|
|
57
|
+
"eslint": "^9.25.1",
|
|
58
|
+
"tailwindcss": "^4.1.4"
|
|
79
59
|
}
|
|
80
60
|
}
|
package/components/Accordion.vue
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed, provide, ref, watch } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props = defineProps<{
|
|
5
|
-
modelValue?: string | number
|
|
6
|
-
}>()
|
|
7
|
-
const emit = defineEmits(['update:modelValue'])
|
|
8
|
-
|
|
9
|
-
const _value = ref(props.modelValue)
|
|
10
|
-
watch(() => props.modelValue, (val) => {
|
|
11
|
-
_value.value = val
|
|
12
|
-
})
|
|
13
|
-
const value = computed({
|
|
14
|
-
get: () => _value.value,
|
|
15
|
-
set: (val) => {
|
|
16
|
-
_value.value = val
|
|
17
|
-
if (props.modelValue !== val)
|
|
18
|
-
emit('update:modelValue', val)
|
|
19
|
-
},
|
|
20
|
-
})
|
|
21
|
-
|
|
22
|
-
provide('accordion-value', value)
|
|
23
|
-
</script>
|
|
24
|
-
|
|
25
|
-
<template>
|
|
26
|
-
<div class="daisy-ui-kit-accordion">
|
|
27
|
-
<slot />
|
|
28
|
-
</div>
|
|
29
|
-
</template>
|
package/components/Alert.vue
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props: any = defineProps<{
|
|
5
|
-
type?: string
|
|
6
|
-
info?: boolean
|
|
7
|
-
success?: boolean
|
|
8
|
-
warning?: boolean
|
|
9
|
-
error?: boolean
|
|
10
|
-
}>()
|
|
11
|
-
const classes = computed(() => {
|
|
12
|
-
return {
|
|
13
|
-
'alert-info': props.info || props.type === 'info',
|
|
14
|
-
'alert-success': props.success || props.type === 'success',
|
|
15
|
-
'alert-warning': props.warning || props.type === 'warning',
|
|
16
|
-
'alert-error': props.error || props.type === 'error',
|
|
17
|
-
}
|
|
18
|
-
})
|
|
19
|
-
</script>
|
|
20
|
-
|
|
21
|
-
<template>
|
|
22
|
-
<div class="alert" :class="classes">
|
|
23
|
-
<slot />
|
|
24
|
-
</div>
|
|
25
|
-
</template>
|
package/components/Artboard.vue
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props = defineProps<{
|
|
5
|
-
demo?: boolean
|
|
6
|
-
horizontal?: boolean
|
|
7
|
-
size?: string
|
|
8
|
-
phone1?: boolean
|
|
9
|
-
phone2?: boolean
|
|
10
|
-
phone3?: boolean
|
|
11
|
-
phone4?: boolean
|
|
12
|
-
phone5?: boolean
|
|
13
|
-
phone6?: boolean
|
|
14
|
-
}>()
|
|
15
|
-
const classes = computed(() => {
|
|
16
|
-
return {
|
|
17
|
-
'artboard-demo': props.demo,
|
|
18
|
-
'horizontal': props.horizontal,
|
|
19
|
-
'phone-1': props.phone1 || props.size === 'phone-1',
|
|
20
|
-
'phone-2': props.phone2 || props.size === 'phone-2',
|
|
21
|
-
'phone-3': props.phone3 || props.size === 'phone-3',
|
|
22
|
-
'phone-4': props.phone4 || props.size === 'phone-4',
|
|
23
|
-
'phone-5': props.phone5 || props.size === 'phone-5',
|
|
24
|
-
'phone-6': props.phone6 || props.size === 'phone-6',
|
|
25
|
-
}
|
|
26
|
-
})
|
|
27
|
-
</script>
|
|
28
|
-
|
|
29
|
-
<template>
|
|
30
|
-
<div class="artboard" :class="classes">
|
|
31
|
-
<slot />
|
|
32
|
-
</div>
|
|
33
|
-
</template>
|
package/components/Avatar.vue
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
import { makeMaskClasses, maskProps } from './Mask.config'
|
|
4
|
-
import Mask from './Mask.vue'
|
|
5
|
-
|
|
6
|
-
const props = defineProps({
|
|
7
|
-
backgroundColor: { type: String, default: '#BBB' },
|
|
8
|
-
maskClasses: String,
|
|
9
|
-
showStatus: Boolean,
|
|
10
|
-
online: Boolean,
|
|
11
|
-
...maskProps,
|
|
12
|
-
})
|
|
13
|
-
|
|
14
|
-
const classes = computed(() => {
|
|
15
|
-
return {
|
|
16
|
-
online: props.showStatus && props.online,
|
|
17
|
-
}
|
|
18
|
-
})
|
|
19
|
-
|
|
20
|
-
const internalMaskClasses = makeMaskClasses(props)
|
|
21
|
-
const allMaskClasses = computed(() => {
|
|
22
|
-
const classes = internalMaskClasses.value
|
|
23
|
-
const hasMaskClass = Object.values(classes).find(v => v)
|
|
24
|
-
// Enable rounded-btn class only if no mask classes are applied
|
|
25
|
-
Object.assign(classes, { 'rounded-btn': !hasMaskClass })
|
|
26
|
-
return classes
|
|
27
|
-
})
|
|
28
|
-
|
|
29
|
-
const color = computed(() => {
|
|
30
|
-
return `#${contrastingColor(props.backgroundColor.replace('#', ''))}`
|
|
31
|
-
})
|
|
32
|
-
|
|
33
|
-
function contrastingColor(color: any) {
|
|
34
|
-
return (luma(color) >= 155) ? '000' : 'fff'
|
|
35
|
-
}
|
|
36
|
-
// color can be a hx string or an array of RGB values 0-255
|
|
37
|
-
function luma(color: any) {
|
|
38
|
-
const rgb = (typeof color === 'string') ? hexToRGBArray(color) : color
|
|
39
|
-
return (0.2126 * rgb[0]) + (0.7152 * rgb[1]) + (0.0722 * rgb[2]) // SMPTE C, Rec. 709 weightings
|
|
40
|
-
}
|
|
41
|
-
function hexToRGBArray(color: any) {
|
|
42
|
-
if (color.length === 3)
|
|
43
|
-
color = color.charAt(0) + color.charAt(0) + color.charAt(1) + color.charAt(1) + color.charAt(2) + color.charAt(2)
|
|
44
|
-
else if (color.length !== 6)
|
|
45
|
-
throw new Error(`Invalid hex color: ${color}`)
|
|
46
|
-
const rgb = []
|
|
47
|
-
for (let i = 0; i <= 2; i++)
|
|
48
|
-
rgb[i] = Number.parseInt(color.substr(i * 2, 2), 16)
|
|
49
|
-
return rgb
|
|
50
|
-
}
|
|
51
|
-
</script>
|
|
52
|
-
|
|
53
|
-
<template>
|
|
54
|
-
<div class="avatar" :class="classes">
|
|
55
|
-
<Mask :style="{ backgroundColor, color }" class="w-full h-full avatar-mask aspect-square" :class="[allMaskClasses, maskClasses]">
|
|
56
|
-
<slot />
|
|
57
|
-
</Mask>
|
|
58
|
-
</div>
|
|
59
|
-
</template>
|
|
60
|
-
|
|
61
|
-
<style lang="postcss">
|
|
62
|
-
.avatar-mask > * {
|
|
63
|
-
aspect-ratio: 1/1;
|
|
64
|
-
width: 100%;
|
|
65
|
-
height: 100%;
|
|
66
|
-
display: flex;
|
|
67
|
-
align-items: center;
|
|
68
|
-
justify-content: center;
|
|
69
|
-
}
|
|
70
|
-
</style>
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props = defineProps({
|
|
5
|
-
vertical: Boolean,
|
|
6
|
-
})
|
|
7
|
-
const classes = computed(() => {
|
|
8
|
-
return {
|
|
9
|
-
'flex-col': props.vertical,
|
|
10
|
-
'flex-row': !props.vertical,
|
|
11
|
-
}
|
|
12
|
-
})
|
|
13
|
-
</script>
|
|
14
|
-
|
|
15
|
-
<template>
|
|
16
|
-
<div class="avatar-group" :class="classes">
|
|
17
|
-
<slot />
|
|
18
|
-
</div>
|
|
19
|
-
</template>
|
package/components/Badge.vue
DELETED
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props = defineProps<{
|
|
5
|
-
outline?: boolean
|
|
6
|
-
|
|
7
|
-
size?: string
|
|
8
|
-
lg?: boolean
|
|
9
|
-
md?: boolean
|
|
10
|
-
sm?: boolean
|
|
11
|
-
xs?: boolean
|
|
12
|
-
|
|
13
|
-
color?: string
|
|
14
|
-
neutral?: boolean
|
|
15
|
-
primary?: boolean
|
|
16
|
-
secondary?: boolean
|
|
17
|
-
accent?: boolean
|
|
18
|
-
info?: boolean
|
|
19
|
-
success?: boolean
|
|
20
|
-
warning?: boolean
|
|
21
|
-
error?: boolean
|
|
22
|
-
|
|
23
|
-
ghost?: boolean
|
|
24
|
-
}>()
|
|
25
|
-
|
|
26
|
-
const classes = computed(() => {
|
|
27
|
-
return {
|
|
28
|
-
'badge-outline': props.outline,
|
|
29
|
-
'badge-ghost': props.ghost,
|
|
30
|
-
'badge-lg': props.lg || props.size === 'lg',
|
|
31
|
-
'badge-md': props.md || props.size === 'md',
|
|
32
|
-
'badge-sm': props.sm || props.size === 'sm',
|
|
33
|
-
'badge-xs': props.xs || props.size === 'xs',
|
|
34
|
-
'badge-neutral': props.neutral || props.color === 'neutral',
|
|
35
|
-
'badge-primary': props.primary || props.color === 'primary',
|
|
36
|
-
'badge-secondary': props.secondary || props.color === 'secondary',
|
|
37
|
-
'badge-accent': props.accent || props.color === 'accent',
|
|
38
|
-
'badge-info': props.info || props.color === 'info',
|
|
39
|
-
'badge-success': props.success || props.color === 'success',
|
|
40
|
-
'badge-warning': props.warning || props.color === 'warning',
|
|
41
|
-
'badge-error': props.error || props.color === 'error',
|
|
42
|
-
}
|
|
43
|
-
})
|
|
44
|
-
</script>
|
|
45
|
-
|
|
46
|
-
<template>
|
|
47
|
-
<div class="badge" :class="classes">
|
|
48
|
-
<slot />
|
|
49
|
-
</div>
|
|
50
|
-
</template>
|
package/components/BottomNav.vue
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props = defineProps<{
|
|
5
|
-
size?: string
|
|
6
|
-
lg?: boolean
|
|
7
|
-
md?: boolean
|
|
8
|
-
sm?: boolean
|
|
9
|
-
xs?: boolean
|
|
10
|
-
}>()
|
|
11
|
-
const classes = computed(() => {
|
|
12
|
-
return {
|
|
13
|
-
'btm-nav-lg': props.lg || props.size === 'lg',
|
|
14
|
-
'btm-nav-md': props.md || props.size === 'md',
|
|
15
|
-
'btm-nav-sm': props.sm || props.size === 'sm',
|
|
16
|
-
'btm-nav-xs': props.xs || props.size === 'xs',
|
|
17
|
-
}
|
|
18
|
-
})
|
|
19
|
-
</script>
|
|
20
|
-
|
|
21
|
-
<template>
|
|
22
|
-
<div class="btm-nav" :class="classes">
|
|
23
|
-
<slot />
|
|
24
|
-
</div>
|
|
25
|
-
</template>
|
package/components/Button.vue
DELETED
|
@@ -1,111 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props = defineProps<{
|
|
5
|
-
is?: string
|
|
6
|
-
join?: boolean
|
|
7
|
-
|
|
8
|
-
color?: string
|
|
9
|
-
neutral?: boolean
|
|
10
|
-
primary?: boolean
|
|
11
|
-
secondary?: boolean
|
|
12
|
-
accent?: boolean
|
|
13
|
-
info?: boolean
|
|
14
|
-
success?: boolean
|
|
15
|
-
warning?: boolean
|
|
16
|
-
error?: boolean
|
|
17
|
-
|
|
18
|
-
ghost?: boolean
|
|
19
|
-
link?: boolean
|
|
20
|
-
glass?: boolean
|
|
21
|
-
outline?: boolean
|
|
22
|
-
disabled?: boolean
|
|
23
|
-
|
|
24
|
-
shape?: 'circle' | 'square' | 'wide' | 'block'
|
|
25
|
-
circle?: boolean
|
|
26
|
-
square?: boolean
|
|
27
|
-
wide?: boolean
|
|
28
|
-
block?: boolean
|
|
29
|
-
|
|
30
|
-
noAnimation?: boolean
|
|
31
|
-
active?: boolean
|
|
32
|
-
|
|
33
|
-
size?: 'lg' | 'md' | 'sm' | 'xs'
|
|
34
|
-
lg?: boolean
|
|
35
|
-
md?: boolean
|
|
36
|
-
sm?: boolean
|
|
37
|
-
xs?: boolean
|
|
38
|
-
|
|
39
|
-
type?: 'button' | 'submit' | 'reset'
|
|
40
|
-
}>()
|
|
41
|
-
|
|
42
|
-
const classes = computed(() => {
|
|
43
|
-
return {
|
|
44
|
-
'join-item': props.join,
|
|
45
|
-
|
|
46
|
-
'btn-primary': !props.disabled && (props.primary || props.color === 'primary'),
|
|
47
|
-
'btn-secondary': !props.disabled && (props.secondary || props.color === 'secondary'),
|
|
48
|
-
'btn-neutral': !props.disabled && (props.neutral || props.color === 'neutral'),
|
|
49
|
-
'btn-accent': !props.disabled && (props.accent || props.color === 'accent'),
|
|
50
|
-
'btn-info': !props.disabled && (props.info || props.color === 'info'),
|
|
51
|
-
'btn-success': !props.disabled && (props.success || props.color === 'success'),
|
|
52
|
-
'btn-warning': !props.disabled && (props.warning || props.color === 'warning'),
|
|
53
|
-
'btn-error': !props.disabled && (props.error || props.color === 'error'),
|
|
54
|
-
|
|
55
|
-
'text-primary': !props.disabled && (props.primary || props.color === 'primary') && props.link,
|
|
56
|
-
'text-secondary': !props.disabled && (props.secondary || props.color === 'secondary') && props.link,
|
|
57
|
-
'text-neutral': !props.disabled && (props.neutral || props.color === 'neutral') && props.link,
|
|
58
|
-
'text-accent': !props.disabled && (props.accent || props.color === 'accent') && props.link,
|
|
59
|
-
'text-info': !props.disabled && (props.info || props.color === 'info') && props.link,
|
|
60
|
-
'text-success': !props.disabled && (props.success || props.color === 'success') && props.link,
|
|
61
|
-
'text-warning': !props.disabled && (props.warning || props.color === 'warning') && props.link,
|
|
62
|
-
'text-error': !props.disabled && (props.error || props.color === 'error') && props.link,
|
|
63
|
-
|
|
64
|
-
'glass': !props.disabled && props.glass,
|
|
65
|
-
|
|
66
|
-
'btn-circle': props.circle || props.shape === 'circle',
|
|
67
|
-
'btn-square': props.square || props.shape === 'square',
|
|
68
|
-
'btn-wide': props.wide || props.shape === 'wide',
|
|
69
|
-
'btn-block': props.block || props.shape === 'block',
|
|
70
|
-
|
|
71
|
-
'btn-lg': props.lg || props.size === 'lg',
|
|
72
|
-
'btn-md': props.md || props.size === 'md',
|
|
73
|
-
'btn-sm': props.sm || props.size === 'sm',
|
|
74
|
-
'btn-xs': props.xs || props.size === 'xs',
|
|
75
|
-
|
|
76
|
-
'btn-outline': !props.disabled && props.outline,
|
|
77
|
-
'btn-ghost': !props.disabled && props.ghost,
|
|
78
|
-
'btn-link': !props.disabled && props.link,
|
|
79
|
-
'btn-disabled': props.disabled,
|
|
80
|
-
|
|
81
|
-
'no-animation': props.noAnimation,
|
|
82
|
-
'btn-active': !props.disabled && props.active,
|
|
83
|
-
}
|
|
84
|
-
})
|
|
85
|
-
|
|
86
|
-
// Accessibility-friendly attributes for disabling the button
|
|
87
|
-
const disabledAttrs = computed(() => {
|
|
88
|
-
if (props.disabled) {
|
|
89
|
-
return {
|
|
90
|
-
'tabindex': -1,
|
|
91
|
-
'role': 'button',
|
|
92
|
-
'aria-disabled': true,
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
else {
|
|
96
|
-
return {}
|
|
97
|
-
}
|
|
98
|
-
})
|
|
99
|
-
</script>
|
|
100
|
-
|
|
101
|
-
<template>
|
|
102
|
-
<component
|
|
103
|
-
:is="is || 'button'"
|
|
104
|
-
:type="type"
|
|
105
|
-
class="btn"
|
|
106
|
-
:class="[classes]"
|
|
107
|
-
v-bind="{ ...disabledAttrs, ...$attrs }"
|
|
108
|
-
>
|
|
109
|
-
<slot />
|
|
110
|
-
</component>
|
|
111
|
-
</template>
|
package/components/Card.vue
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props = withDefaults(defineProps<{
|
|
5
|
-
is?: string | Object | Function
|
|
6
|
-
bordered?: boolean
|
|
7
|
-
compact?: boolean
|
|
8
|
-
side?: boolean
|
|
9
|
-
imageFull?: boolean
|
|
10
|
-
glass?: boolean
|
|
11
|
-
}>(), {
|
|
12
|
-
is: 'div',
|
|
13
|
-
})
|
|
14
|
-
|
|
15
|
-
const classes = computed(() => {
|
|
16
|
-
return {
|
|
17
|
-
'card-bordered': props.bordered,
|
|
18
|
-
'card-compact': props.compact,
|
|
19
|
-
'card-side': props.side,
|
|
20
|
-
'image-full': props.imageFull,
|
|
21
|
-
'glass': props.glass,
|
|
22
|
-
}
|
|
23
|
-
})
|
|
24
|
-
</script>
|
|
25
|
-
|
|
26
|
-
<template>
|
|
27
|
-
<component :is="is" class="card" :class="classes">
|
|
28
|
-
<slot />
|
|
29
|
-
</component>
|
|
30
|
-
</template>
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import Text from './Text.vue'
|
|
3
|
-
|
|
4
|
-
interface Props {
|
|
5
|
-
is?: string
|
|
6
|
-
}
|
|
7
|
-
withDefaults(defineProps<Props>(), {
|
|
8
|
-
is: 'div',
|
|
9
|
-
})
|
|
10
|
-
</script>
|
|
11
|
-
|
|
12
|
-
<template>
|
|
13
|
-
<Text :is="is" class="card-actions">
|
|
14
|
-
<slot />
|
|
15
|
-
</Text>
|
|
16
|
-
</template>
|
package/components/CardBody.vue
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import Text from './Text.vue'
|
|
3
|
-
|
|
4
|
-
interface Props {
|
|
5
|
-
is?: string
|
|
6
|
-
}
|
|
7
|
-
withDefaults(defineProps<Props>(), {
|
|
8
|
-
is: 'div',
|
|
9
|
-
})
|
|
10
|
-
</script>
|
|
11
|
-
|
|
12
|
-
<template>
|
|
13
|
-
<Text :is="is" class="card-body">
|
|
14
|
-
<slot />
|
|
15
|
-
</Text>
|
|
16
|
-
</template>
|
package/components/CardTitle.vue
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import Text from './Text.vue'
|
|
3
|
-
|
|
4
|
-
interface Props {
|
|
5
|
-
is?: string
|
|
6
|
-
}
|
|
7
|
-
withDefaults(defineProps<Props>(), {
|
|
8
|
-
is: 'div',
|
|
9
|
-
})
|
|
10
|
-
</script>
|
|
11
|
-
|
|
12
|
-
<template>
|
|
13
|
-
<Text :is="is" class="card-title">
|
|
14
|
-
<slot />
|
|
15
|
-
</Text>
|
|
16
|
-
</template>
|