dolphin-components 3.1.2 → 3.1.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/dist/dolphin-components-test-2.css +1 -0
- package/dist/dolphin-components.cjs.js +97 -97
- package/dist/dolphin-components.es.js +6430 -6364
- package/dist/dolphin-components.umd.js +97 -97
- package/dist/index.d.ts +4 -5
- package/eslint/eslint-rules.cjs +25 -0
- package/eslint/pinia/eslint-pinia.cjs +73 -0
- package/eslint/pinia/eslint-pinia.test.cjs +69 -0
- package/package.json +85 -67
- package/dist/dolphin-components.css +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -16,7 +16,7 @@ title: ContentTitle[];
|
|
|
16
16
|
bodyClass: string;
|
|
17
17
|
titleClass: string;
|
|
18
18
|
disableMinHeight: boolean;
|
|
19
|
-
}, {}, {}, {}, string, ComponentProvideOptions, false, {},
|
|
19
|
+
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
20
20
|
|
|
21
21
|
declare const __VLS_component_2: DefineComponent<ModalProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
22
22
|
[x: string]: never;
|
|
@@ -44,7 +44,7 @@ body2Width: number;
|
|
|
44
44
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
45
45
|
|
|
46
46
|
declare type __VLS_Props = {
|
|
47
|
-
show
|
|
47
|
+
show?: boolean;
|
|
48
48
|
files?: FileInput | FileInput[];
|
|
49
49
|
initialIndex?: number;
|
|
50
50
|
};
|
|
@@ -57,7 +57,7 @@ declare function __VLS_template(): {
|
|
|
57
57
|
body?(_: {}): any;
|
|
58
58
|
};
|
|
59
59
|
refs: {};
|
|
60
|
-
rootEl:
|
|
60
|
+
rootEl: any;
|
|
61
61
|
};
|
|
62
62
|
|
|
63
63
|
declare function __VLS_template_2(): {
|
|
@@ -271,7 +271,6 @@ classValue: string;
|
|
|
271
271
|
export declare const InputCurrency: {
|
|
272
272
|
mounted(el: CurrencyInputElement, binding: DirectiveBinding): void;
|
|
273
273
|
updated(el: HTMLInputElement, binding: DirectiveBinding): void;
|
|
274
|
-
unmounted(el: HTMLInputElement): void;
|
|
275
274
|
};
|
|
276
275
|
|
|
277
276
|
export declare const InputError: {
|
|
@@ -391,7 +390,7 @@ enableHeaderPrint: boolean;
|
|
|
391
390
|
enableFooterPrint: boolean;
|
|
392
391
|
enableHeaderBlock: boolean;
|
|
393
392
|
enableFooterBlock: boolean;
|
|
394
|
-
}, {}, {}, {}, string, ComponentProvideOptions, false, {},
|
|
393
|
+
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
395
394
|
|
|
396
395
|
export declare interface TabulatorAction {
|
|
397
396
|
name: string;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
const noDuplicatePiniaStoreIds = require("./pinia/eslint-pinia.cjs");
|
|
2
|
+
|
|
3
|
+
const plugin = {
|
|
4
|
+
meta: {
|
|
5
|
+
name: "dolphin-eslint-plugin",
|
|
6
|
+
version: "1.0.0",
|
|
7
|
+
},
|
|
8
|
+
rules: {
|
|
9
|
+
"no-duplicate-pinia-store-ids": noDuplicatePiniaStoreIds,
|
|
10
|
+
},
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
module.exports = {
|
|
14
|
+
plugin,
|
|
15
|
+
configs: {
|
|
16
|
+
recommended: {
|
|
17
|
+
plugins: {
|
|
18
|
+
dolphin: plugin,
|
|
19
|
+
},
|
|
20
|
+
rules: {
|
|
21
|
+
"dolphin/no-duplicate-pinia-store-ids": "error",
|
|
22
|
+
},
|
|
23
|
+
},
|
|
24
|
+
},
|
|
25
|
+
};
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
const storeIds = new Map();
|
|
4
|
+
|
|
5
|
+
module.exports = {
|
|
6
|
+
meta: {
|
|
7
|
+
type: "problem",
|
|
8
|
+
docs: {
|
|
9
|
+
description: "Disallow duplicate Pinia defineStore ids",
|
|
10
|
+
},
|
|
11
|
+
schema: [],
|
|
12
|
+
messages: {
|
|
13
|
+
duplicate: "Pinia store id '{{id}}' is already defined in {{file}}.",
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
|
|
17
|
+
create(context) {
|
|
18
|
+
const filename = context.getFilename();
|
|
19
|
+
|
|
20
|
+
function reportIfDuplicate(id, node) {
|
|
21
|
+
const existingFile = storeIds.get(id);
|
|
22
|
+
|
|
23
|
+
if (existingFile === filename) {
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
if (existingFile) {
|
|
28
|
+
context.report({
|
|
29
|
+
node,
|
|
30
|
+
messageId: "duplicate",
|
|
31
|
+
data: {
|
|
32
|
+
id,
|
|
33
|
+
file: existingFile,
|
|
34
|
+
},
|
|
35
|
+
});
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
storeIds.set(id, filename);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
return {
|
|
43
|
+
CallExpression(node) {
|
|
44
|
+
if (
|
|
45
|
+
node.callee.type === "Identifier" &&
|
|
46
|
+
node.callee.name === "defineStore" &&
|
|
47
|
+
node.arguments.length > 0
|
|
48
|
+
) {
|
|
49
|
+
const firstArg = node.arguments[0];
|
|
50
|
+
|
|
51
|
+
if (firstArg.type === "Literal" && typeof firstArg.value === "string") {
|
|
52
|
+
reportIfDuplicate(firstArg.value, firstArg);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
if (firstArg.type === "ObjectExpression") {
|
|
56
|
+
const idProp = firstArg.properties.find(
|
|
57
|
+
(p) =>
|
|
58
|
+
p.type === "Property" &&
|
|
59
|
+
p.key.type === "Identifier" &&
|
|
60
|
+
p.key.name === "id" &&
|
|
61
|
+
p.value.type === "Literal" &&
|
|
62
|
+
typeof p.value.value === "string"
|
|
63
|
+
);
|
|
64
|
+
|
|
65
|
+
if (idProp) {
|
|
66
|
+
reportIfDuplicate(idProp.value.value, idProp.value);
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
};
|
|
72
|
+
},
|
|
73
|
+
};
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
const { RuleTester } = require("eslint");
|
|
4
|
+
const rule = require("./eslint-pinia.cjs");
|
|
5
|
+
|
|
6
|
+
const ruleTester = new RuleTester({
|
|
7
|
+
languageOptions: {
|
|
8
|
+
ecmaVersion: 2020,
|
|
9
|
+
sourceType: "module",
|
|
10
|
+
},
|
|
11
|
+
});
|
|
12
|
+
|
|
13
|
+
ruleTester.run("no-duplicate-pinia-store-ids", rule, {
|
|
14
|
+
valid: [
|
|
15
|
+
{
|
|
16
|
+
code: `
|
|
17
|
+
import { defineStore } from 'pinia'
|
|
18
|
+
defineStore('user')
|
|
19
|
+
`,
|
|
20
|
+
filename: "stores/user.js",
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
code: `
|
|
24
|
+
import { defineStore } from 'pinia'
|
|
25
|
+
defineStore('profile')
|
|
26
|
+
`,
|
|
27
|
+
filename: "stores/profile.js",
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
code: `
|
|
31
|
+
import { defineStore } from 'pinia'
|
|
32
|
+
defineStore({
|
|
33
|
+
id: 'settings',
|
|
34
|
+
state: () => ({})
|
|
35
|
+
})
|
|
36
|
+
`,
|
|
37
|
+
filename: "stores/settings.js",
|
|
38
|
+
},
|
|
39
|
+
],
|
|
40
|
+
|
|
41
|
+
invalid: [
|
|
42
|
+
{
|
|
43
|
+
code: `
|
|
44
|
+
import { defineStore } from 'pinia'
|
|
45
|
+
defineStore('user')
|
|
46
|
+
`,
|
|
47
|
+
filename: "stores/user-duplicate.js",
|
|
48
|
+
errors: [
|
|
49
|
+
{
|
|
50
|
+
message: "Pinia store id 'user' is already defined in stores/user.js.",
|
|
51
|
+
},
|
|
52
|
+
],
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
code: `
|
|
56
|
+
import { defineStore } from 'pinia'
|
|
57
|
+
defineStore({
|
|
58
|
+
id: 'settings'
|
|
59
|
+
})
|
|
60
|
+
`,
|
|
61
|
+
filename: "stores/settings-duplicate.js",
|
|
62
|
+
errors: [
|
|
63
|
+
{
|
|
64
|
+
message: "Pinia store id 'settings' is already defined in stores/settings.js.",
|
|
65
|
+
},
|
|
66
|
+
],
|
|
67
|
+
},
|
|
68
|
+
],
|
|
69
|
+
});
|
package/package.json
CHANGED
|
@@ -1,69 +1,87 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
2
|
+
"name": "dolphin-components",
|
|
3
|
+
"private": false,
|
|
4
|
+
"version": "3.1.3",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"files": [
|
|
7
|
+
"dist",
|
|
8
|
+
"eslint"
|
|
9
|
+
],
|
|
10
|
+
"engines": {
|
|
11
|
+
"node": ">=24"
|
|
12
|
+
},
|
|
13
|
+
"author": "<Mavorion Systems> (https://mavorion.com/)",
|
|
14
|
+
"homepage": "https://mavorion.com/",
|
|
15
|
+
"license": "Apache-2.0",
|
|
16
|
+
"main": "./dist/dolphin-components.umd.cjs",
|
|
17
|
+
"module": "./dist/dolphin-components.es.js",
|
|
18
|
+
"exports": {
|
|
19
|
+
".": {
|
|
20
|
+
"types": "./dist/index.d.ts",
|
|
21
|
+
"import": "./dist/dolphin-components.es.js",
|
|
22
|
+
"require": "./dist/dolphin-components.umd.cjs"
|
|
11
23
|
},
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
"
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
"
|
|
26
|
-
"
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
"
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
"
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
"
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
24
|
+
"./dolphin-components.css": "./dist/dolphin-components.css",
|
|
25
|
+
"./eslint": "./eslint/eslint-rules.cjs"
|
|
26
|
+
},
|
|
27
|
+
"types": "./dist/index.d.ts",
|
|
28
|
+
"dependencies": {
|
|
29
|
+
"@tailwindcss/vite": "^4.1.18",
|
|
30
|
+
"@types/tabulator-tables": "^6.3.1",
|
|
31
|
+
"axios": "^1.13.2",
|
|
32
|
+
"lucide-vue-next": "^0.561.0",
|
|
33
|
+
"moment": "^2.30.1",
|
|
34
|
+
"nepali-date-library": "^1.1.12",
|
|
35
|
+
"nepali-datepicker-vue": "^1.0.12",
|
|
36
|
+
"sweetalert2": "^11.26.17",
|
|
37
|
+
"tabulator-tables": "^6.3.1",
|
|
38
|
+
"tailwindcss": "^4.1.18",
|
|
39
|
+
"utility-types": "^3.11.0",
|
|
40
|
+
"vue": "^3.5.27",
|
|
41
|
+
"vue-datepicker-next": "^1.0.3",
|
|
42
|
+
"vue-multiselect": "^3.4.0",
|
|
43
|
+
"xlsx": "https://cdn.sheetjs.com/xlsx-0.20.3/xlsx-0.20.3.tgz"
|
|
44
|
+
},
|
|
45
|
+
"peerDependencies": {
|
|
46
|
+
"vue-router": "^4.5.0",
|
|
47
|
+
"eslint": "^9.39.2"
|
|
48
|
+
},
|
|
49
|
+
"devDependencies": {
|
|
50
|
+
"@eslint/js": "^9.39.2",
|
|
51
|
+
"@tsconfig/node24": "^24.0.4",
|
|
52
|
+
"@types/node": "^25.0.9",
|
|
53
|
+
"@vitejs/plugin-vue": "^6.0.3",
|
|
54
|
+
"@vue/eslint-config-prettier": "^10.2.0",
|
|
55
|
+
"@vue/eslint-config-typescript": "^14.6.0",
|
|
56
|
+
"@vue/tsconfig": "^0.8.1",
|
|
57
|
+
"eslint-plugin-prettier": "^5.5.5",
|
|
58
|
+
"eslint-plugin-vue": "^10.7.0",
|
|
59
|
+
"globals": "^17.0.0",
|
|
60
|
+
"jiti": "^2.6.1",
|
|
61
|
+
"npm-run-all2": "^8.0.4",
|
|
62
|
+
"path": "^0.12.7",
|
|
63
|
+
"prettier": "3.8.0",
|
|
64
|
+
"typescript": "~5.9.3",
|
|
65
|
+
"typescript-eslint": "^8.53.1",
|
|
66
|
+
"vite": "^7.3.1",
|
|
67
|
+
"vite-plugin-dts": "^4.5.4",
|
|
68
|
+
"vite-plugin-vue-devtools": "^8.0.5",
|
|
69
|
+
"vue-tsc": "^3.2.2"
|
|
70
|
+
},
|
|
71
|
+
"keywords": [
|
|
72
|
+
"mavorion",
|
|
73
|
+
"dolphin"
|
|
74
|
+
],
|
|
75
|
+
"scripts": {
|
|
76
|
+
"dev": "vite --host",
|
|
77
|
+
"prebuild": "npm run lint",
|
|
78
|
+
"build": "run-p type-check \"build-only {@}\" --",
|
|
79
|
+
"preview": "vite preview",
|
|
80
|
+
"build-only": "vite build",
|
|
81
|
+
"type-check": "vue-tsc --declaration --emitDeclarationOnly",
|
|
82
|
+
"format": "prettier --write src/",
|
|
83
|
+
"format:check": "prettier --check src/",
|
|
84
|
+
"lint": "eslint src --max-warnings 0",
|
|
85
|
+
"lint:fix": "eslint src --fix"
|
|
86
|
+
}
|
|
87
|
+
}
|