fds-vue-core 6.2.4 → 6.2.6
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/dist/fds-vue-core.cjs.js +3 -3
- package/dist/fds-vue-core.cjs.js.map +1 -1
- package/dist/fds-vue-core.es.js +3 -3
- package/dist/fds-vue-core.es.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +39 -32
- package/src/components/FdsWeekCalendar/FdsWeekCalendar.vue +3 -4
- package/src/components/FdsWeekCalendar/types.ts +2 -2
- package/src/components/FdsWeekCalendar/weekCalendar.utils.ts +3 -2
package/package.json
CHANGED
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fds-vue-core",
|
|
3
|
-
"version": "6.2.
|
|
3
|
+
"version": "6.2.6",
|
|
4
4
|
"description": "FDS Vue Core Component Library",
|
|
5
5
|
"type": "module",
|
|
6
|
-
"bin": {
|
|
7
|
-
"fds-vuln-commit": "./scripts/vuln-commit.mjs"
|
|
8
|
-
},
|
|
9
6
|
"main": "./dist/fds-vue-core.cjs.js",
|
|
10
7
|
"module": "./dist/fds-vue-core.es.js",
|
|
11
8
|
"types": "./components.d.ts",
|
|
@@ -23,22 +20,13 @@
|
|
|
23
20
|
"./fonts.css": "./dist/fonts.css",
|
|
24
21
|
"./FdsTable.css": "./dist/FdsTable.css",
|
|
25
22
|
"./FdsInput.css": "./dist/FdsInput.css",
|
|
26
|
-
"./tailwind.preset.cjs": "./tailwind.preset.cjs"
|
|
27
|
-
"./tsconfig.base.json": "./configs/tsconfig.base.json",
|
|
28
|
-
"./eslint.config.base.js": "./configs/eslint.config.base.js",
|
|
29
|
-
"./prettier.config.js": "./configs/prettier.config.js",
|
|
30
|
-
"./vscode-settings.json": "./configs/vscode-settings.json",
|
|
31
|
-
"./vuln-commit": "./scripts/vuln-commit.mjs",
|
|
32
|
-
"./cz-adapter": "./scripts/cz/cz-adapter.cjs",
|
|
33
|
-
"./cz-config": "./scripts/cz/.cz-config.cjs"
|
|
23
|
+
"./tailwind.preset.cjs": "./tailwind.preset.cjs"
|
|
34
24
|
},
|
|
35
25
|
"files": [
|
|
36
26
|
"dist",
|
|
37
27
|
"src",
|
|
38
28
|
"components.d.ts",
|
|
39
|
-
"tailwind.preset.cjs"
|
|
40
|
-
"configs",
|
|
41
|
-
"scripts"
|
|
29
|
+
"tailwind.preset.cjs"
|
|
42
30
|
],
|
|
43
31
|
"license": "UNLICENSED",
|
|
44
32
|
"keywords": [
|
|
@@ -51,6 +39,23 @@
|
|
|
51
39
|
"engines": {
|
|
52
40
|
"node": "^20.19.0 || >=22.12.0"
|
|
53
41
|
},
|
|
42
|
+
"scripts": {
|
|
43
|
+
"serve": "vite",
|
|
44
|
+
"build": "vite build && pnpm build:types && cp ./src/tokens.css ./dist/tokens.css && cp ./src/slot-styles.css ./dist/slot-styles.css && cp ./src/apply.css ./dist/apply.css && cp ./src/fonts.css ./dist/fonts.css && cp -r ./public/assets ./dist/assets && mkdir -p ./dist/assets/img/logos && cp -r ./src/assets/img/logos/* ./dist/assets/img/logos/",
|
|
45
|
+
"build:types": "pnpm exec fgd typecheck --project tsconfig.build.json",
|
|
46
|
+
"preview": "vite preview",
|
|
47
|
+
"lint": "pnpm exec fgd lint --fix .",
|
|
48
|
+
"lint:ts": "pnpm exec fgd typecheck --noEmit -p tsconfig.app.json",
|
|
49
|
+
"lint:all": "pnpm lint && pnpm lint:ts",
|
|
50
|
+
"format": "prettier --write src/",
|
|
51
|
+
"prepublishOnly": "pnpm build",
|
|
52
|
+
"storybook": "STORYBOOK=true storybook dev -p 6006",
|
|
53
|
+
"build-storybook": "STORYBOOK=true storybook build",
|
|
54
|
+
"yalc:publish": "pnpm build && yalc publish",
|
|
55
|
+
"yalc:push": "pnpm build && yalc push",
|
|
56
|
+
"serve:playground": "pnpm --dir playground-consumer dev",
|
|
57
|
+
"lint-check": "pnpm exec fgd lint ."
|
|
58
|
+
},
|
|
54
59
|
"config": {
|
|
55
60
|
"commitizen": {
|
|
56
61
|
"path": "./scripts/cz/cz-adapter.cjs"
|
|
@@ -96,20 +101,22 @@
|
|
|
96
101
|
"src/apply.css"
|
|
97
102
|
]
|
|
98
103
|
},
|
|
99
|
-
"
|
|
100
|
-
"
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
"
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
}
|
|
104
|
+
"pnpm": {
|
|
105
|
+
"overrides": {
|
|
106
|
+
"follow-redirects@<=1.15.11": ">=1.16.0",
|
|
107
|
+
"lodash@<=4.17.23": ">=4.18.0",
|
|
108
|
+
"lodash@>=4.0.0 <=4.17.22": ">=4.17.23",
|
|
109
|
+
"lodash@>=4.0.0 <=4.17.23": ">=4.18.0",
|
|
110
|
+
"tmp@<=0.2.3": ">=0.2.4",
|
|
111
|
+
"minimatch@>=10.0.0 <10.2.3": ">=10.2.3"
|
|
112
|
+
},
|
|
113
|
+
"onlyBuiltDependencies": [
|
|
114
|
+
"@parcel/watcher",
|
|
115
|
+
"core-js-pure",
|
|
116
|
+
"esbuild",
|
|
117
|
+
"lefthook",
|
|
118
|
+
"vue-demi"
|
|
119
|
+
]
|
|
120
|
+
},
|
|
121
|
+
"packageManager": "pnpm@10.17.1"
|
|
122
|
+
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import {
|
|
3
3
|
addWeeks,
|
|
4
|
-
format,
|
|
5
4
|
getISODay,
|
|
6
5
|
getISOWeek,
|
|
7
6
|
isBefore,
|
|
@@ -39,7 +38,7 @@ const props = withDefaults(defineProps<FdsWeekCalendarProps>(), {
|
|
|
39
38
|
|
|
40
39
|
const emit = defineEmits<{
|
|
41
40
|
(e: 'change-date-range', event: WeekDateRange, week?: Date): void
|
|
42
|
-
(e: 'select-date', event:
|
|
41
|
+
(e: 'select-date', event: Date | null): void
|
|
43
42
|
(e: 'decrement-week'): void
|
|
44
43
|
(e: 'increment-week'): void
|
|
45
44
|
}>()
|
|
@@ -119,13 +118,13 @@ watch(
|
|
|
119
118
|
() => props.selected,
|
|
120
119
|
(newSelected) => {
|
|
121
120
|
selectedDay.value = newSelected ?? null
|
|
122
|
-
emit('select-date', newSelected
|
|
121
|
+
emit('select-date', newSelected ?? null)
|
|
123
122
|
},
|
|
124
123
|
)
|
|
125
124
|
|
|
126
125
|
const onHandleSelectedDay = (weekDay: Date | null) => {
|
|
127
126
|
selectedDay.value = weekDay
|
|
128
|
-
emit('select-date', weekDay
|
|
127
|
+
emit('select-date', weekDay)
|
|
129
128
|
}
|
|
130
129
|
|
|
131
130
|
const onHandleSetCurrentWeek = (week: Date) => {
|
|
@@ -12,7 +12,7 @@ export interface FdsWeekCalendarLoading {
|
|
|
12
12
|
|
|
13
13
|
export interface FdsWeekCalendarProps extends /* @vue-ignore */ HTMLAttributes {
|
|
14
14
|
loading?: FdsWeekCalendarLoading
|
|
15
|
-
enabledDates?:
|
|
15
|
+
enabledDates?: Date[]
|
|
16
16
|
disablePreviousWeek?: boolean
|
|
17
17
|
disableNextWeek?: boolean
|
|
18
18
|
enableHorizontalAnimation?: boolean
|
|
@@ -23,6 +23,6 @@ export interface FdsWeekCalendarProps extends /* @vue-ignore */ HTMLAttributes {
|
|
|
23
23
|
weekLabel?: string
|
|
24
24
|
onDecrementWeek?: () => void
|
|
25
25
|
onIncrementWeek?: () => void
|
|
26
|
-
onSelectDate?: (date:
|
|
26
|
+
onSelectDate?: (date: Date | null) => void
|
|
27
27
|
onChangeDateRange?: (dateRange: WeekDateRange, week?: Date) => void
|
|
28
28
|
}
|
|
@@ -2,6 +2,7 @@ import {
|
|
|
2
2
|
addDays,
|
|
3
3
|
format,
|
|
4
4
|
isAfter,
|
|
5
|
+
isSameDay,
|
|
5
6
|
isSameMonth,
|
|
6
7
|
startOfDay,
|
|
7
8
|
startOfISOWeek,
|
|
@@ -58,5 +59,5 @@ export const checkIfDateIsBeforeToday = (date: Date): boolean => {
|
|
|
58
59
|
return isAfter(startOfToday, startOfDate)
|
|
59
60
|
}
|
|
60
61
|
|
|
61
|
-
export const checkIfDateIsEnabled = (date: Date, enabledDates:
|
|
62
|
-
enabledDates.
|
|
62
|
+
export const checkIfDateIsEnabled = (date: Date, enabledDates: Date[]): boolean =>
|
|
63
|
+
enabledDates.some((enabledDate) => isSameDay(enabledDate, date))
|