daisy-ui-kit 3.0.12 → 5.0.0-pre.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/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/components/Tooltip.vue
DELETED
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { computed } from 'vue'
|
|
3
|
-
|
|
4
|
-
const props = defineProps<{
|
|
5
|
-
tip?: string | number
|
|
6
|
-
open?: 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
|
-
position?: 'top' | 'right' | 'bottom' | 'left'
|
|
19
|
-
top?: boolean
|
|
20
|
-
right?: boolean
|
|
21
|
-
bottom?: boolean
|
|
22
|
-
left?: boolean
|
|
23
|
-
}>()
|
|
24
|
-
const classes = computed(() => {
|
|
25
|
-
return {
|
|
26
|
-
'tooltip-open': props.open,
|
|
27
|
-
'tooltip-top': props.top || props.position === 'top',
|
|
28
|
-
'tooltip-bottom': props.bottom || props.position === 'bottom',
|
|
29
|
-
'tooltip-left': props.left || props.position === 'left',
|
|
30
|
-
'tooltip-right': props.right || props.position === 'right',
|
|
31
|
-
'tooltip-primary': props.primary || props.color === 'primary',
|
|
32
|
-
'tooltip-secondary': props.secondary || props.color === 'secondary',
|
|
33
|
-
'tooltip-neutral': props.neutral || props.color === 'neutral',
|
|
34
|
-
'tooltip-accent': props.accent || props.color === 'accent',
|
|
35
|
-
'tooltip-info': props.info || props.color === 'info',
|
|
36
|
-
'tooltip-success': props.success || props.color === 'success',
|
|
37
|
-
'tooltip-warning': props.warning || props.color === 'warning',
|
|
38
|
-
'tooltip-error': props.error || props.color === 'error',
|
|
39
|
-
}
|
|
40
|
-
})
|
|
41
|
-
</script>
|
|
42
|
-
|
|
43
|
-
<template>
|
|
44
|
-
<div :data-tip="tip" class="tooltip" :class="classes">
|
|
45
|
-
<slot />
|
|
46
|
-
</div>
|
|
47
|
-
</template>
|
package/index.ts
DELETED
|
@@ -1,108 +0,0 @@
|
|
|
1
|
-
export { default as Accordion } from './components/Accordion.vue'
|
|
2
|
-
export { default as Alert } from './components/Alert.vue'
|
|
3
|
-
export { default as Artboard } from './components/Artboard.vue'
|
|
4
|
-
export { default as Avatar } from './components/Avatar.vue'
|
|
5
|
-
export { default as AvatarGroup } from './components/AvatarGroup.vue'
|
|
6
|
-
export { default as Badge } from './components/Badge.vue'
|
|
7
|
-
export { default as BottomNav } from './components/BottomNav.vue'
|
|
8
|
-
export { default as Breadcrumbs } from './components/Breadcrumbs.vue'
|
|
9
|
-
export { default as Button } from './components/Button.vue'
|
|
10
|
-
export { default as Card } from './components/Card.vue'
|
|
11
|
-
export { default as CardActions } from './components/CardActions.vue'
|
|
12
|
-
export { default as CardBody } from './components/CardBody.vue'
|
|
13
|
-
export { default as CardTitle } from './components/CardTitle.vue'
|
|
14
|
-
export { default as Carousel } from './components/Carousel.vue'
|
|
15
|
-
export { default as CarouselItem } from './components/CarouselItem.vue'
|
|
16
|
-
export { default as Chat } from './components/Chat.vue'
|
|
17
|
-
export { default as ChatBubble } from './components/ChatBubble.vue'
|
|
18
|
-
export { default as ChatFooter } from './components/ChatFooter.vue'
|
|
19
|
-
export { default as ChatHeader } from './components/ChatHeader.vue'
|
|
20
|
-
export { default as ChatImage } from './components/ChatImage.vue'
|
|
21
|
-
export { default as Checkbox } from './components/Checkbox.vue'
|
|
22
|
-
export { default as Collapse } from './components/Collapse.vue'
|
|
23
|
-
export { default as CollapseContent } from './components/CollapseContent.vue'
|
|
24
|
-
export { default as CollapseTitle } from './components/CollapseTitle.vue'
|
|
25
|
-
export { default as Countdown } from './components/Countdown.vue'
|
|
26
|
-
export { default as CountdownTimers } from './components/CountdownTimers.vue'
|
|
27
|
-
export { default as Counter } from './components/Counter.vue'
|
|
28
|
-
export { default as Crumb } from './components/Crumb.vue'
|
|
29
|
-
export { default as Divider } from './components/Divider.vue'
|
|
30
|
-
export { default as Drawer } from './components/Drawer.vue'
|
|
31
|
-
export { default as DrawerContent } from './components/DrawerContent.vue'
|
|
32
|
-
export { default as DrawerSide } from './components/DrawerSide.vue'
|
|
33
|
-
export { default as Dropdown } from './components/Dropdown.vue'
|
|
34
|
-
export { default as DropdownContent } from './components/DropdownContent.vue'
|
|
35
|
-
export { default as DropdownButton } from './components/DropdownButton.vue'
|
|
36
|
-
export { default as DropdownTarget } from './components/DropdownTarget.vue'
|
|
37
|
-
export { default as FileInput } from './components/FileInput.vue'
|
|
38
|
-
export { default as Flex } from './components/Flex.vue'
|
|
39
|
-
export { default as FlexItem } from './components/FlexItem.vue'
|
|
40
|
-
export { default as Footer } from './components/Footer.vue'
|
|
41
|
-
export { default as FooterTitle } from './components/FooterTitle.vue'
|
|
42
|
-
export { default as FormControl } from './components/FormControl.vue'
|
|
43
|
-
export { default as Hero } from './components/Hero.vue'
|
|
44
|
-
export { default as HeroContent } from './components/HeroContent.vue'
|
|
45
|
-
export { default as HeroOverlay } from './components/HeroOverlay.vue'
|
|
46
|
-
export { default as Indicator } from './components/Indicator.vue'
|
|
47
|
-
export { default as IndicatorItem } from './components/IndicatorItem.vue'
|
|
48
|
-
export { default as Join } from './components/Join.vue'
|
|
49
|
-
export { default as Kbd } from './components/Kbd.vue'
|
|
50
|
-
export { default as Label } from './components/Label.vue'
|
|
51
|
-
export { default as LabelText } from './components/LabelText.vue'
|
|
52
|
-
export { default as LabelTextAlt } from './components/LabelTextAlt.vue'
|
|
53
|
-
export { default as Link } from './components/Link.vue'
|
|
54
|
-
export { default as LoadingBall } from './components/LoadingBall.vue'
|
|
55
|
-
export { default as LoadingBars } from './components/LoadingBars.vue'
|
|
56
|
-
export { default as LoadingDots } from './components/LoadingDots.vue'
|
|
57
|
-
export { default as LoadingInfinity } from './components/LoadingInfinity.vue'
|
|
58
|
-
export { default as LoadingRing } from './components/LoadingRing.vue'
|
|
59
|
-
export { default as LoadingSpinner } from './components/LoadingSpinner.vue'
|
|
60
|
-
export { default as Mask } from './components/Mask.vue'
|
|
61
|
-
export { default as Menu } from './components/Menu.vue'
|
|
62
|
-
export { default as MenuItem } from './components/MenuItem.vue'
|
|
63
|
-
export { default as MenuTitle } from './components/MenuTitle.vue'
|
|
64
|
-
export { default as MenuExpand } from './components/MenuExpand.vue'
|
|
65
|
-
export { default as MenuExpandToggle } from './components/MenuExpandToggle.vue'
|
|
66
|
-
export { default as MockupCode } from './components/MockupCode.vue'
|
|
67
|
-
export { default as MockupBrowser } from './components/MockupBrowser.vue'
|
|
68
|
-
export { default as MockupBrowserToolbar } from './components/MockupBrowserToolbar.vue'
|
|
69
|
-
export { default as MockupPhone } from './components/MockupPhone.vue'
|
|
70
|
-
export { default as MockupWindow } from './components/MockupWindow.vue'
|
|
71
|
-
export { default as Modal } from './components/Modal.vue'
|
|
72
|
-
export { default as ModalAction } from './components/ModalAction.vue'
|
|
73
|
-
export { default as ModalBox } from './components/ModalBox.vue'
|
|
74
|
-
export { default as Navbar } from './components/Navbar.vue'
|
|
75
|
-
export { default as NavbarCenter } from './components/NavbarCenter.vue'
|
|
76
|
-
export { default as NavbarEnd } from './components/NavbarEnd.vue'
|
|
77
|
-
export { default as NavbarStart } from './components/NavbarStart.vue'
|
|
78
|
-
export { default as NavButton } from './components/NavButton.vue'
|
|
79
|
-
export { default as Progress } from './components/Progress.vue'
|
|
80
|
-
export { default as Prose } from './components/Prose.vue'
|
|
81
|
-
export { default as RadialProgress } from './components/RadialProgress.vue'
|
|
82
|
-
export { default as Radio } from './components/Radio.vue'
|
|
83
|
-
export { default as RadioGroup } from './components/RadioGroup.vue'
|
|
84
|
-
export { default as Range } from './components/Range.vue'
|
|
85
|
-
export { default as RangeMeasure } from './components/RangeMeasure.vue'
|
|
86
|
-
export { default as Rating } from './components/Rating.vue'
|
|
87
|
-
export { default as Select } from './components/Select.vue'
|
|
88
|
-
export { default as Stack } from './components/Stack.vue'
|
|
89
|
-
export { default as Stat } from './components/Stat.vue'
|
|
90
|
-
export { default as StatActions } from './components/StatActions.vue'
|
|
91
|
-
export { default as StatDesc } from './components/StatDesc.vue'
|
|
92
|
-
export { default as StatFigure } from './components/StatFigure.vue'
|
|
93
|
-
export { default as Stats } from './components/Stats.vue'
|
|
94
|
-
export { default as StatTitle } from './components/StatTitle.vue'
|
|
95
|
-
export { default as StatValue } from './components/StatValue.vue'
|
|
96
|
-
export { default as Step } from './components/Step.vue'
|
|
97
|
-
export { default as Steps } from './components/Steps.vue'
|
|
98
|
-
export { default as Swap } from './components/Swap.vue'
|
|
99
|
-
export { default as Tab } from './components/Tab.vue'
|
|
100
|
-
export { default as TabContent } from './components/TabContent.vue'
|
|
101
|
-
export { default as Tabs } from './components/Tabs.vue'
|
|
102
|
-
export { default as TabsManager } from './components/TabsManager.vue'
|
|
103
|
-
export { default as Text } from './components/Text.vue'
|
|
104
|
-
export { default as TextArea } from './components/TextArea.vue'
|
|
105
|
-
export { default as TextInput } from './components/TextInput.vue'
|
|
106
|
-
export { default as Toast } from './components/Toast.vue'
|
|
107
|
-
export { default as Toggle } from './components/Toggle.vue'
|
|
108
|
-
export { default as Tooltip } from './components/Tooltip.vue'
|
package/nuxt.js
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { fileURLToPath } from 'node:url'
|
|
2
|
-
import { defineNuxtModule } from '@nuxt/kit'
|
|
3
|
-
|
|
4
|
-
export default defineNuxtModule({
|
|
5
|
-
meta: {
|
|
6
|
-
name: 'daisy-ui-kit',
|
|
7
|
-
configKey: 'daisy',
|
|
8
|
-
},
|
|
9
|
-
defaults: {
|
|
10
|
-
prefix: '',
|
|
11
|
-
},
|
|
12
|
-
setup(moduleOptions, nuxt) {
|
|
13
|
-
const { prefix } = moduleOptions
|
|
14
|
-
|
|
15
|
-
nuxt.hook('components:dirs', (dirs) => {
|
|
16
|
-
dirs.push({
|
|
17
|
-
path: fileURLToPath(new URL('./components', import.meta.url)),
|
|
18
|
-
prefix,
|
|
19
|
-
})
|
|
20
|
-
})
|
|
21
|
-
},
|
|
22
|
-
})
|
package/utils/-utils.ts
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { computed } from 'vue'
|
|
2
|
-
|
|
3
|
-
interface MakeExclusiveClassOptions {
|
|
4
|
-
props: Record<string, any>
|
|
5
|
-
prefix: string
|
|
6
|
-
prop: string
|
|
7
|
-
propList: string[]
|
|
8
|
-
defaultVal?: string
|
|
9
|
-
}
|
|
10
|
-
/**
|
|
11
|
-
* Creates a className for the provided `prop` name and checks that multiple are not enabled.
|
|
12
|
-
* @param prefix will be added to all classes that do not begin with `-`. For those that do, the `-` will be stripped.
|
|
13
|
-
* @param prop
|
|
14
|
-
* @param propList
|
|
15
|
-
* @param defaultVal
|
|
16
|
-
*/
|
|
17
|
-
export function makeExclusiveClass({
|
|
18
|
-
props,
|
|
19
|
-
prefix,
|
|
20
|
-
prop,
|
|
21
|
-
propList,
|
|
22
|
-
defaultVal = '',
|
|
23
|
-
}: MakeExclusiveClassOptions) {
|
|
24
|
-
return computed(() => {
|
|
25
|
-
const active = propList.filter((v: string) => props[v.replace('-', '')])
|
|
26
|
-
if (active.length > 1) {
|
|
27
|
-
throw new Error(
|
|
28
|
-
`only one ${prop} can be enabled at a time. Current are ${active}`
|
|
29
|
-
)
|
|
30
|
-
}
|
|
31
|
-
const current = active[0] || ''
|
|
32
|
-
const _prefix = current.startsWith('-') ? '' : prefix
|
|
33
|
-
return current ? `${_prefix}${current.replace('-', '') || defaultVal}` : ''
|
|
34
|
-
})
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
export function makeIndividualClass({ props, prefix, prop }) {
|
|
38
|
-
return computed(() => {
|
|
39
|
-
return props[prop] ? `${prefix}${prop}` : ''
|
|
40
|
-
})
|
|
41
|
-
}
|
package/utils/Button.config.ts
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
export * from './-utils'
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Converts a list of prop names to an object of Booleans. Can be spread into props.
|
|
5
|
-
* @param propList list of prop names to become booleans
|
|
6
|
-
*/
|
|
7
|
-
export function toProps(propList: string[]): Record<string, boolean> {
|
|
8
|
-
return propList.reduce((all: Record<string, any>, current: string) => {
|
|
9
|
-
all[current.replace('-', '')] = Boolean
|
|
10
|
-
return all
|
|
11
|
-
}, {})
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
export const directionVariants = ['top', 'bottom', 'left', 'right']
|
|
15
|
-
export const colorVariants = ['neutral', 'primary', 'secondary', 'accent']
|
|
16
|
-
export const stateVariants = ['info', 'success', 'warning', 'error']
|
|
17
|
-
export const allColorVariants = [...colorVariants, ...stateVariants]
|
|
18
|
-
export const variants = [
|
|
19
|
-
...colorVariants,
|
|
20
|
-
...stateVariants,
|
|
21
|
-
'ghost',
|
|
22
|
-
'link',
|
|
23
|
-
'glass',
|
|
24
|
-
]
|
|
25
|
-
export const sizes = ['xs', 'sm', 'md', 'lg']
|
|
26
|
-
export const shapes = ['circle', 'square']
|
package/utils/drawer-utils.ts
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { reactive } from 'vue'
|
|
2
|
-
|
|
3
|
-
export interface DrawerState {
|
|
4
|
-
name: string
|
|
5
|
-
isDrawerOpen: boolean
|
|
6
|
-
openDrawer: () => void
|
|
7
|
-
closeDrawer: () => void
|
|
8
|
-
toggleDrawer: () => void
|
|
9
|
-
}
|
|
10
|
-
export interface Drawers {
|
|
11
|
-
[key: string]: DrawerState
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
export const drawers = reactive<Drawers>({})
|
|
15
|
-
|
|
16
|
-
export function createDrawerState(name: string) {
|
|
17
|
-
const drawerState = drawers[name] || reactive<DrawerState>({
|
|
18
|
-
name,
|
|
19
|
-
isDrawerOpen: false,
|
|
20
|
-
openDrawer() {
|
|
21
|
-
drawerState.isDrawerOpen = true
|
|
22
|
-
},
|
|
23
|
-
closeDrawer() {
|
|
24
|
-
drawerState.isDrawerOpen = false
|
|
25
|
-
},
|
|
26
|
-
toggleDrawer() {
|
|
27
|
-
drawerState.isDrawerOpen = !drawerState.isDrawerOpen
|
|
28
|
-
},
|
|
29
|
-
})
|
|
30
|
-
drawers[name] = drawerState
|
|
31
|
-
return drawerState
|
|
32
|
-
}
|
package/utils/fixtures.ts
DELETED
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
export const people = [
|
|
2
|
-
{
|
|
3
|
-
id: 1,
|
|
4
|
-
name: 'Wade Cooper',
|
|
5
|
-
avatar:
|
|
6
|
-
'https://images.unsplash.com/photo-1491528323818-fdd1faba62cc?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
7
|
-
},
|
|
8
|
-
{
|
|
9
|
-
id: 2,
|
|
10
|
-
name: 'Arlene Mccoy',
|
|
11
|
-
avatar:
|
|
12
|
-
'https://images.unsplash.com/photo-1550525811-e5869dd03032?ixlib=rb-1.2.1&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
13
|
-
},
|
|
14
|
-
{
|
|
15
|
-
id: 3,
|
|
16
|
-
name: 'Devon Webb',
|
|
17
|
-
avatar:
|
|
18
|
-
'https://images.unsplash.com/photo-1500648767791-00dcc994a43e?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2.25&w=256&h=256&q=80',
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
id: 4,
|
|
22
|
-
name: 'Tom Cook',
|
|
23
|
-
avatar:
|
|
24
|
-
'https://images.unsplash.com/photo-1472099645785-5658abf4ff4e?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
id: 5,
|
|
28
|
-
name: 'Tanya Fox',
|
|
29
|
-
avatar:
|
|
30
|
-
'https://images.unsplash.com/photo-1494790108377-be9c29b29330?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
id: 6,
|
|
34
|
-
name: 'Hellen Schmidt',
|
|
35
|
-
avatar:
|
|
36
|
-
'https://images.unsplash.com/photo-1487412720507-e7ab37603c6f?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
id: 7,
|
|
40
|
-
name: 'Caroline Schultz',
|
|
41
|
-
avatar:
|
|
42
|
-
'https://images.unsplash.com/photo-1568409938619-12e139227838?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
id: 8,
|
|
46
|
-
name: 'Mason Heaney',
|
|
47
|
-
avatar:
|
|
48
|
-
'https://images.unsplash.com/photo-1531427186611-ecfd6d936c79?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
id: 9,
|
|
52
|
-
name: 'Claudie Smitham',
|
|
53
|
-
avatar:
|
|
54
|
-
'https://images.unsplash.com/photo-1584486520270-19eca1efcce5?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
55
|
-
},
|
|
56
|
-
{
|
|
57
|
-
id: 10,
|
|
58
|
-
name: 'Emil Schaefer',
|
|
59
|
-
avatar:
|
|
60
|
-
'https://images.unsplash.com/photo-1561505457-3bcad021f8ee?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80',
|
|
61
|
-
},
|
|
62
|
-
]
|
package/utils/random-string.ts
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generate a random string of `length` characters
|
|
3
|
-
*
|
|
4
|
-
* Usage:
|
|
5
|
-
* const myString = randomString(15); // This will give you a random string of 15 characters
|
|
6
|
-
* @param length The length of the string to generate
|
|
7
|
-
* @returns A random string of `length` characters
|
|
8
|
-
*/
|
|
9
|
-
export function randomString(length: number = 10): string {
|
|
10
|
-
const characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'
|
|
11
|
-
let result = ''
|
|
12
|
-
|
|
13
|
-
for (let i = 0; i < length; i++) {
|
|
14
|
-
const randomIndex = Math.floor(Math.random() * characters.length)
|
|
15
|
-
result += characters[randomIndex]
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
return result
|
|
19
|
-
}
|