@webitel/ui-datalist 1.1.2 → 1.1.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/package.json CHANGED
@@ -1,98 +1,98 @@
1
1
  {
2
- "name": "@webitel/ui-datalist",
3
- "version": "1.1.2",
4
- "description": "Toolkit for building data lists in webitel ui system",
5
- "scripts": {
6
- "make-all": "npm version patch --git-tag-version false && ( npm run lint:fix || true) && (npm run build:types || true) && npm run utils:publish",
7
- "build:types": "vue-tsc -p ./tsconfig.build.json",
8
- "lint:fix": "eslint --fix ./src && prettier --write --check ./src",
9
- "lint:fix-staged": "npx lint-staged",
10
- "lint:package": "publint",
11
- "utils:i": "npm i",
12
- "utils:link": "npm link",
13
- "utils:publish": "npm publish --access public"
14
- },
15
- "type": "module",
16
- "main": "./src/index.ts",
17
- "types": "./types/index.d.ts",
18
- "workspaces": [
19
- "../../",
20
- "../styleguide",
21
- "../api-services"
22
- ],
23
- "files": [
24
- "src/*",
25
- "types/",
26
- "Readme.md",
27
- "CHANGELOG.md"
28
- ],
29
- "peerDependencies": {
30
- "@regle/schemas": "^1.x",
31
- "@vuelidate/core": "^2.0.3",
32
- "@vuelidate/validators": "^2.0.4",
33
- "@vueuse/core": "^14.0",
34
- "@webitel/api-services": "^0.1.0",
35
- "@webitel/styleguide": "^26.2.0-1",
36
- "@webitel/ui-sdk": "^26.2.0-2",
37
- "axios": "^1",
38
- "date-fns": "^4",
39
- "pinia": "^3.x",
40
- "vue": "^3.5",
41
- "zod": "^4.x"
42
- },
43
- "devDependencies": {
44
- "@eslint/js": "^9.22.0",
45
- "@standard-schema/spec": "^1.x",
46
- "@tsconfig/node22": "^22.0.0",
47
- "@types/node": "^24.x",
48
- "@vue/tsconfig": "^0.8.x",
49
- "eslint": "^9.22.0",
50
- "eslint-config-prettier": "^10.1.1",
51
- "eslint-plugin-simple-import-sort": "^12.1.1",
52
- "eslint-plugin-vue": "^10.0.0",
53
- "globals": "^17.x",
54
- "globby": "^16.x",
55
- "lint-staged": "^16.x",
56
- "prettier": "^3.5.3",
57
- "prettier-plugin-css-order": "^2.1.2",
58
- "publint": "^0.3.9",
59
- "sass": "^1.85.1",
60
- "typescript": "5.9.x",
61
- "typescript-eslint": "^8.26.1",
62
- "typescript-plugin-css-modules": "^5.x",
63
- "unplugin-auto-import": "^19.x",
64
- "vue-tsc": "^3.x"
65
- },
66
- "engines": {
67
- "npm": "11",
68
- "node": "v24"
69
- },
70
- "repository": {
71
- "type": "git",
72
- "url": "https://github.com/webitel/webitel-ui-sdk"
73
- },
74
- "keywords": [
75
- "webitel",
76
- "webitel-ui"
77
- ],
78
- "author": "webitel",
79
- "license": "ISC",
80
- "exports": {
81
- ".": {
82
- "types": "./types/index.d.ts",
83
- "import": "./src/index.ts"
84
- },
85
- "./filters": {
86
- "types": "./types/modules/filters/index.d.ts",
87
- "import": "./src/modules/filters/index.ts"
88
- },
89
- "./presets": {
90
- "types": "./types/modules/filter-presets/index.d.ts",
91
- "import": "./src/modules/filter-presets/index.ts"
92
- },
93
- "./card": {
94
- "types": "./types/modules/card/index.d.ts",
95
- "import": "./src/modules/card/index.ts"
96
- }
97
- }
2
+ "name": "@webitel/ui-datalist",
3
+ "version": "1.1.4",
4
+ "description": "Toolkit for building data lists in webitel ui system",
5
+ "scripts": {
6
+ "make-all": "npm version patch --git-tag-version false && ( npm run lint:fix || true) && (npm run build:types || true) && npm run utils:publish",
7
+ "build:types": "vue-tsc -p ./tsconfig.build.json",
8
+ "lint:fix": "eslint --fix ./src && prettier --write --check ./src",
9
+ "lint:fix-staged": "npx lint-staged",
10
+ "lint:package": "publint",
11
+ "utils:i": "npm i",
12
+ "utils:link": "npm link",
13
+ "utils:publish": "npm publish --access public"
14
+ },
15
+ "type": "module",
16
+ "main": "./src/index.ts",
17
+ "types": "./types/index.d.ts",
18
+ "workspaces": [
19
+ "../../",
20
+ "../styleguide",
21
+ "../api-services"
22
+ ],
23
+ "files": [
24
+ "src/*",
25
+ "types/",
26
+ "Readme.md",
27
+ "CHANGELOG.md"
28
+ ],
29
+ "peerDependencies": {
30
+ "@regle/schemas": "^1.x",
31
+ "@vuelidate/core": "^2.0.3",
32
+ "@vuelidate/validators": "^2.0.4",
33
+ "@vueuse/core": "^14.0",
34
+ "@webitel/api-services": "^0.1.0",
35
+ "@webitel/styleguide": "^26.2.53",
36
+ "@webitel/ui-sdk": "^26.2.53",
37
+ "axios": "^1",
38
+ "date-fns": "^4",
39
+ "pinia": "^3.x",
40
+ "vue": "^3.5",
41
+ "zod": "^4.x"
42
+ },
43
+ "devDependencies": {
44
+ "@eslint/js": "^9.22.0",
45
+ "@standard-schema/spec": "^1.x",
46
+ "@tsconfig/node22": "^22.0.0",
47
+ "@types/node": "^24.x",
48
+ "@vue/tsconfig": "^0.8.x",
49
+ "eslint": "^9.22.0",
50
+ "eslint-config-prettier": "^10.1.1",
51
+ "eslint-plugin-simple-import-sort": "^12.1.1",
52
+ "eslint-plugin-vue": "^10.0.0",
53
+ "globals": "^17.x",
54
+ "globby": "^16.x",
55
+ "lint-staged": "^16.x",
56
+ "prettier": "^3.5.3",
57
+ "prettier-plugin-css-order": "^2.1.2",
58
+ "publint": "^0.3.9",
59
+ "sass": "^1.85.1",
60
+ "typescript": "5.9.x",
61
+ "typescript-eslint": "^8.26.1",
62
+ "typescript-plugin-css-modules": "^5.x",
63
+ "unplugin-auto-import": "^19.x",
64
+ "vue-tsc": "^3.x"
65
+ },
66
+ "engines": {
67
+ "npm": "11",
68
+ "node": "v24"
69
+ },
70
+ "repository": {
71
+ "type": "git",
72
+ "url": "https://github.com/webitel/webitel-ui-sdk"
73
+ },
74
+ "keywords": [
75
+ "webitel",
76
+ "webitel-ui"
77
+ ],
78
+ "author": "webitel",
79
+ "license": "ISC",
80
+ "exports": {
81
+ ".": {
82
+ "types": "./types/index.d.ts",
83
+ "import": "./src/index.ts"
84
+ },
85
+ "./filters": {
86
+ "types": "./types/modules/filters/index.d.ts",
87
+ "import": "./src/modules/filters/index.ts"
88
+ },
89
+ "./presets": {
90
+ "types": "./types/modules/filter-presets/index.d.ts",
91
+ "import": "./src/modules/filter-presets/index.ts"
92
+ },
93
+ "./card": {
94
+ "types": "./types/modules/card/index.d.ts",
95
+ "import": "./src/modules/card/index.ts"
96
+ }
97
+ }
98
98
  }
@@ -3,18 +3,18 @@
3
3
  <wt-timepicker
4
4
  v-if="model"
5
5
  :label="t('reusable.from')"
6
- :value="model.from"
6
+ :model-value="model.from"
7
7
  :v="v$.model?.from"
8
8
  format="mm:ss"
9
- @input="handleInput('from', $event)"
9
+ @update:model-value="handleInput('from', $event)"
10
10
  />
11
11
  <wt-timepicker
12
12
  v-if="model"
13
13
  :label="t('reusable.to')"
14
- :value="model.to"
14
+ :model-value="model.to"
15
15
  :v="v$.model?.to"
16
16
  format="mm:ss"
17
- @input="handleInput('to', $event)"
17
+ @update:model-value="handleInput('to', $event)"
18
18
  />
19
19
  </div>
20
20
  </template>
@@ -27,55 +27,65 @@ import { useI18n } from 'vue-i18n';
27
27
  const { t } = useI18n();
28
28
 
29
29
  type ModelValue = {
30
- from: number;
31
- to: number;
30
+ from: number;
31
+ to: number;
32
32
  };
33
33
 
34
34
  const model = defineModel<ModelValue>();
35
35
 
36
36
  const emit = defineEmits<{
37
- 'update:invalid': [boolean];
37
+ 'update:invalid': [
38
+ boolean,
39
+ ];
38
40
  }>();
39
41
 
40
42
  if (!model.value) {
41
- model.value = {
42
- from: 0,
43
- to: 0,
44
- };
43
+ model.value = {
44
+ from: 0,
45
+ to: 0,
46
+ };
45
47
  }
46
48
 
47
49
  const isValueEmpty = () => {
48
- return !!model?.value?.to || !!model?.value?.from;
50
+ return !!model?.value?.to || !!model?.value?.from;
49
51
  };
50
52
 
51
53
  const v$ = useVuelidate(
52
- computed(() => ({
53
- model: {
54
- from: {
55
- required: isValueEmpty,
56
- },
57
- to: {
58
- required: isValueEmpty,
59
- },
60
- },
61
- })),
62
- { model },
63
- { $autoDirty: true },
54
+ computed(() => ({
55
+ model: {
56
+ from: {
57
+ required: isValueEmpty,
58
+ },
59
+ to: {
60
+ required: isValueEmpty,
61
+ },
62
+ },
63
+ })),
64
+ {
65
+ model,
66
+ },
67
+ {
68
+ $autoDirty: true,
69
+ },
64
70
  );
65
71
  v$.value.$touch();
66
72
 
67
73
  const handleInput = (key: keyof ModelValue, value: number) => {
68
- const newValue = { ...model.value };
69
- newValue[key] = value;
70
- model.value = newValue;
74
+ const newValue = {
75
+ ...model.value,
76
+ };
77
+ newValue[key] = value;
78
+ model.value = newValue;
71
79
  };
72
80
 
73
81
  watch(
74
- () => v$.value.$invalid,
75
- (invalid) => {
76
- emit('update:invalid', invalid);
77
- },
78
- { immediate: true },
82
+ () => v$.value.$invalid,
83
+ (invalid) => {
84
+ emit('update:invalid', invalid);
85
+ },
86
+ {
87
+ immediate: true,
88
+ },
79
89
  );
80
90
  </script>
81
91