fds-vue-core 6.2.2 → 6.2.5

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.
@@ -1,74 +0,0 @@
1
- {
2
- "i18n-ally.localesPaths": ["src/lang"],
3
- "i18n-ally.sourceLanguage": "sv",
4
- "i18n-ally.displayLanguage": "sv",
5
- "i18n-ally.keystyle": "nested",
6
- "editor.defaultFormatter": "esbenp.prettier-vscode",
7
- "editor.formatOnSave": true,
8
- "[javascript]": {
9
- "editor.defaultFormatter": "esbenp.prettier-vscode"
10
- },
11
- "[typescript]": {
12
- "editor.defaultFormatter": "esbenp.prettier-vscode"
13
- },
14
- "editor.codeActionsOnSave": {
15
- "source.fixAll.eslint": "explicit",
16
- "source.organizeImports": "explicit"
17
- },
18
- "editor.formatOnSaveMode": "file",
19
- "typescript.format.semicolons": "remove",
20
- "javascript.format.semicolons": "remove",
21
- "editor.quickSuggestions": {
22
- "other": true,
23
- "comments": false,
24
- "strings": true
25
- },
26
- "editor.suggest.showKeywords": true,
27
- "editor.suggest.showSnippets": false,
28
- "editor.suggest.showFolders": false,
29
- "editor.wordBasedSuggestions": "off",
30
- "editor.suggestOnTriggerCharacters": true,
31
- "editor.tabCompletion": "on",
32
- "editor.acceptSuggestionOnCommitCharacter": true,
33
- "editor.quickSuggestionsDelay": 50,
34
- "editor.suggestSelection": "first",
35
- "editor.suggest.localityBonus": true,
36
- "editor.parameterHints.enabled": false,
37
- "editor.inlayHints.enabled": "off",
38
- "editor.suggest.filterGraceful": true,
39
- "eslint.validate": ["javascript", "javascriptreact", "typescript", "typescriptreact", "vue"],
40
- "css.customData": [".vscode/tailwind.json"],
41
- "typescript.tsdk": "node_modules/typescript/lib",
42
- "typescript.enablePromptUseWorkspaceTsdk": true,
43
- "typescript.preferences.includePackageJsonAutoImports": "on",
44
- "typescript.suggest.autoImports": true,
45
- "typescript.updateImportsOnFileMove.enabled": "always",
46
- "typescript.inlayHints.parameterNames.enabled": "none",
47
- "typescript.inlayHints.variableTypes.enabled": false,
48
- "typescript.inlayHints.propertyDeclarationTypes.enabled": false,
49
- "typescript.inlayHints.functionLikeReturnTypes.enabled": false,
50
- "javascript.inlayHints.parameterNames.enabled": "none",
51
- "javascript.inlayHints.variableTypes.enabled": false,
52
- "typescript.suggest.includeCompletionsForImportStatements": true,
53
- "typescript.preferences.importModuleSpecifier": "relative",
54
- "typescript.preferences.importModuleSpecifierEnding": "auto",
55
- "typescript.suggest.completeFunctionCalls": true,
56
- "typescript.suggest.paths": false,
57
- "[vue]": {
58
- "editor.defaultFormatter": "esbenp.prettier-vscode",
59
- "editor.quickSuggestions": {
60
- "other": true,
61
- "comments": false,
62
- "strings": true
63
- },
64
- "editor.suggest.showSnippets": false,
65
- "editor.suggest.showFiles": false,
66
- "editor.suggest.showFolders": false,
67
- "editor.suggest.snippetsPreventQuickSuggestions": true,
68
- "editor.wordBasedSuggestions": "off",
69
- "editor.quickSuggestionsDelay": 50,
70
- "editor.suggestSelection": "first",
71
- "editor.parameterHints.enabled": false,
72
- "editor.inlayHints.enabled": "off"
73
- }
74
- }
@@ -1,22 +0,0 @@
1
- module.exports = {
2
- types: [
3
- { value: 'feat', name: 'feat(scope): Added' },
4
- { value: 'fix', name: 'fix(scope): Fixed' },
5
- { value: 'perf', name: 'perf(scope): Performance' },
6
- { value: 'refactor', name: 'refactor(scope): Changed' },
7
- { value: 'chore', name: 'chore(scope): Changed' },
8
- { value: 'dep', name: 'dep(scope): Dependencies (single package or batch)' },
9
- { value: 'vuln', name: 'vuln(scope): Security dependency update (single package or batch)' },
10
- { value: 'fix(security)', name: 'fix(security): Security' }
11
- ],
12
- allowCustomScopes: true,
13
- allowBreakingChanges: [],
14
- skipQuestions: ['footer', 'breaking'],
15
- subjectLimit: 120,
16
- messages: {
17
- type: 'Select the type of change you are committing:',
18
- customScope: 'Packages (for dep/vuln) or scope:',
19
- subject: 'Commit subject (imperative, no trailing period):',
20
- body: "Optional body (use '|' for newline):"
21
- }
22
- }
@@ -1,112 +0,0 @@
1
- module.exports = {
2
- prompter(cz, commit) {
3
- const types = [
4
- { value: "feat", name: "feat(scope): Added" },
5
- { value: "fix", name: "fix(scope): Fixed" },
6
- { value: "perf", name: "perf(scope): Performance" },
7
- { value: "refactor", name: "refactor(scope): Changed" },
8
- { value: "chore", name: "chore(scope): Changed" },
9
- { value: "docs", name: "docs(scope): Documentation" },
10
- { value: "dep", name: "dep(scope): Dependencies (single package or batch)" },
11
- { value: "vuln", name: "vuln(scope): Security dependency update (single package or batch)" },
12
- { value: "fix(security)", name: "fix(security): Security" },
13
- ];
14
-
15
- const questions = [
16
- {
17
- type: "list",
18
- name: "change_type",
19
- message: "Select the type of change you are committing",
20
- choices: types,
21
- },
22
- {
23
- type: "input",
24
- name: "scope",
25
- when: (answers) => !["dep", "vuln"].includes(answers.change_type),
26
- message: "Scope:",
27
- },
28
- {
29
- type: "input",
30
- name: "packages",
31
- when: (answers) => ["dep", "vuln"].includes(answers.change_type),
32
- message: "Packages:",
33
- },
34
- {
35
- type: "list",
36
- name: "vuln_change_kind",
37
- when: (answers) => answers.change_type === "vuln",
38
- message: "Vulnerability change type:",
39
- choices: [
40
- { value: "override", name: "override" },
41
- { value: "bump", name: "bump" },
42
- ],
43
- },
44
- {
45
- type: "input",
46
- name: "vuln_target_version",
47
- when: (answers) => answers.change_type === "vuln",
48
- message: "Target version/range (e.g. 5.2.2 or >=5.2.2):",
49
- validate: (value) => (value && value.trim() ? true : "Provide a target version/range"),
50
- },
51
- {
52
- type: "list",
53
- name: "dep_change_kind",
54
- when: (answers) => answers.change_type === "dep",
55
- message: "Dependency change type:",
56
- choices: [
57
- { value: "new", name: "new package" },
58
- { value: "update", name: "updated package" },
59
- { value: "remove", name: "removed package" },
60
- ],
61
- },
62
- {
63
- type: "input",
64
- name: "dep_version",
65
- when: (answers) => answers.change_type === "dep",
66
- message: "Version (x.y.z):",
67
- validate: (value) => (/^\d+\.\d+\.\d+$/.test(value) ? true : "Use format x.y.z"),
68
- },
69
- {
70
- type: "input",
71
- name: "shortcut_id",
72
- when: (answers) => !["dep", "vuln"].includes(answers.change_type),
73
- message: "Shortcut ID digits only (optional, e.g. 1234):",
74
- },
75
- {
76
- type: "input",
77
- name: "message",
78
- when: (answers) => !["dep", "vuln"].includes(answers.change_type),
79
- message: "Commit subject (imperative, no trailing period):",
80
- },
81
- {
82
- type: "input",
83
- name: "body",
84
- message: "Optional body (use '|' for newline):",
85
- },
86
- ];
87
-
88
- cz.prompt(questions).then((answers) => {
89
- const type = answers.change_type;
90
- const scopeValue = ["dep", "vuln"].includes(type) ? answers.packages : answers.scope;
91
- const needsEmptyParens = ["dep", "vuln"].includes(type) && !scopeValue;
92
- const scopePart = scopeValue ? `(${scopeValue})` : needsEmptyParens ? "()" : "";
93
- const shortcutPart = answers.shortcut_id ? ` [sc-${answers.shortcut_id}]` : "";
94
- const bodyPart = answers.body ? `\n\n${answers.body.split("|").join("\n")}` : "";
95
- const depSubject =
96
- answers.dep_change_kind === "new"
97
- ? `add ${answers.dep_version}`
98
- : answers.dep_change_kind === "remove"
99
- ? `yeet ${answers.dep_version}`
100
- : `bump to ${answers.dep_version}`;
101
- const vulnSubject =
102
- type === "vuln"
103
- ? answers.vuln_change_kind === "override"
104
- ? `override ${answers.vuln_target_version}`
105
- : `bump to ${answers.vuln_target_version}`
106
- : "";
107
- const subject = type === "dep" ? depSubject : type === "vuln" ? vulnSubject : answers.message;
108
- const commitMessage = `${type}${scopePart}: ${subject}${shortcutPart}${bodyPart}`;
109
- commit(commitMessage);
110
- });
111
- },
112
- };
@@ -1,66 +0,0 @@
1
- #!/usr/bin/env bash
2
-
3
- set -euo pipefail
4
-
5
- bump_type="${1:-}"
6
-
7
- if [[ -z "$bump_type" ]]; then
8
- echo "Select release type:"
9
- echo " 1) patch"
10
- echo " 2) minor"
11
- echo " 3) major"
12
- read -r -p "Enter choice [1-3] (default: 1): " release_choice
13
- release_choice="${release_choice:-1}"
14
- case "$release_choice" in
15
- 1) bump_type="patch" ;;
16
- 2) bump_type="minor" ;;
17
- 3) bump_type="major" ;;
18
- *)
19
- echo "Invalid choice: $release_choice"
20
- exit 1
21
- ;;
22
- esac
23
- fi
24
-
25
- if [[ "$bump_type" != "major" && "$bump_type" != "minor" && "$bump_type" != "patch" ]]; then
26
- echo "Usage: ./scripts/release.sh [major|minor|patch]"
27
- exit 1
28
- fi
29
-
30
- if ! command -v gh >/dev/null 2>&1; then
31
- echo "GitHub CLI (gh) is required but not installed."
32
- exit 1
33
- fi
34
-
35
- if ! gh auth status >/dev/null 2>&1; then
36
- echo "GitHub CLI is not authenticated. Run: gh auth login"
37
- exit 1
38
- fi
39
-
40
- if [[ -n "$(git status --porcelain)" ]]; then
41
- echo "Git working tree is not clean. Commit or stash changes first."
42
- exit 1
43
- fi
44
-
45
- previous_tag="$(git describe --tags --abbrev=0 2>/dev/null || true)"
46
-
47
- pnpm version "$bump_type"
48
-
49
- new_version="$(node -p "require('./package.json').version")"
50
- new_tag="v${new_version}"
51
-
52
- git push
53
- git push --tags
54
-
55
- if [[ -n "$previous_tag" ]]; then
56
- gh release create "$new_tag" \
57
- --latest \
58
- --generate-notes \
59
- --notes-start-tag "$previous_tag"
60
- else
61
- gh release create "$new_tag" \
62
- --latest \
63
- --generate-notes
64
- fi
65
-
66
- echo "Release created: ${new_tag}"
@@ -1,29 +0,0 @@
1
- #!/usr/bin/env node
2
- /**
3
- * Sync selected devDependencies into peerDependencies.
4
- * Keeps published peers aligned with the versions we actually use.
5
- */
6
-
7
- import fs from 'node:fs'
8
- import path from 'node:path'
9
-
10
- const pkgPath = path.resolve(process.cwd(), 'package.json')
11
- const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf8'))
12
-
13
- const sources = { ...pkg.devDependencies, ...pkg.dependencies }
14
-
15
- pkg.peerDependencies = pkg.peerDependencies || {}
16
- const peerKeys = Object.keys(pkg.peerDependencies)
17
-
18
- for (const name of peerKeys) {
19
- const version = sources[name]
20
- if (version) {
21
- pkg.peerDependencies[name] = version
22
- } else {
23
- // If missing locally, leave existing peer version untouched
24
- console.warn(`[sync-peers] Skipping ${name} (not found in devDependencies/dependencies)`)
25
- }
26
- }
27
-
28
- fs.writeFileSync(pkgPath, `${JSON.stringify(pkg, null, 2)}\n`)
29
- console.warn('[sync-peers] peerDependencies updated from devDependencies')
@@ -1,44 +0,0 @@
1
- #!/usr/bin/env node
2
-
3
- /**
4
- * Script to copy fds-vue-core VS Code settings to local .vscode/settings.json
5
- *
6
- * Usage:
7
- * node scripts/sync-vscode-settings.mjs
8
- * # or via npm: npm run sync:vscode
9
- */
10
-
11
- import { copyFileSync, existsSync, mkdirSync } from 'fs'
12
- import { dirname, join } from 'path'
13
-
14
- // Use process.cwd() to get the consuming repo's root directory
15
- // This works correctly even with pnpm/npm link
16
- const projectRoot = process.cwd()
17
-
18
- // Find the base settings file
19
- // First check node_modules (for consuming repos), then check if we're in fds-vue-core itself
20
- const baseSettingsPath = existsSync(
21
- join(projectRoot, 'node_modules', 'fds-vue-core', 'configs', 'vscode-settings.json'),
22
- )
23
- ? join(projectRoot, 'node_modules', 'fds-vue-core', 'configs', 'vscode-settings.json')
24
- : existsSync(join(projectRoot, 'configs', 'vscode-settings.json'))
25
- ? join(projectRoot, 'configs', 'vscode-settings.json')
26
- : null
27
-
28
- const localSettingsPath = join(projectRoot, '.vscode', 'settings.json')
29
-
30
- // Exit silently if fds-vue-core is not installed (for repos that don't use it)
31
- if (!existsSync(baseSettingsPath)) {
32
- process.exit(0)
33
- }
34
-
35
- try {
36
- // Create .vscode directory if it doesn't exist
37
- mkdirSync(dirname(localSettingsPath), { recursive: true })
38
-
39
- // Copy base settings
40
- copyFileSync(baseSettingsPath, localSettingsPath)
41
- } catch (error) {
42
- console.error('❌ Error syncing VS Code settings:', error.message)
43
- process.exit(1)
44
- }
@@ -1,129 +0,0 @@
1
- #!/usr/bin/env node
2
-
3
- import { execSync } from "node:child_process";
4
-
5
- function run(command) {
6
- try {
7
- return execSync(command, { encoding: "utf8" }).trim();
8
- } catch {
9
- return "";
10
- }
11
- }
12
-
13
- function runOrThrow(command) {
14
- return execSync(command, { encoding: "utf8", stdio: "inherit" });
15
- }
16
-
17
- function out(text = "") {
18
- process.stdout.write(`${text}\n`);
19
- }
20
-
21
- function parseJsonAtRef(refPath) {
22
- const raw = run(`git show ${refPath}`);
23
- if (!raw) return null;
24
- try {
25
- return JSON.parse(raw);
26
- } catch {
27
- return null;
28
- }
29
- }
30
-
31
- function readStagedFile(path) {
32
- return parseJsonAtRef(`:${path}`);
33
- }
34
-
35
- function readHeadFile(path) {
36
- return parseJsonAtRef(`HEAD:${path}`);
37
- }
38
-
39
- function collectDeps(pkgJson) {
40
- if (!pkgJson) return {};
41
- return {
42
- ...(pkgJson.dependencies || {}),
43
- ...(pkgJson.devDependencies || {}),
44
- ...(pkgJson.peerDependencies || {}),
45
- ...(pkgJson.optionalDependencies || {}),
46
- ...(pkgJson.overrides || {}),
47
- ...((pkgJson.pnpm && pkgJson.pnpm.overrides) || {}),
48
- };
49
- }
50
-
51
- function normalize(version) {
52
- if (typeof version !== "string") return version;
53
- return version.trim();
54
- }
55
-
56
- function semverFrom(value) {
57
- if (typeof value !== "string") return null;
58
- const match = value.match(/(\d+\.\d+\.\d+)/);
59
- return match ? match[1] : null;
60
- }
61
-
62
- function main() {
63
- const stagedFiles = run("git diff --cached --name-only")
64
- .split("\n")
65
- .map((s) => s.trim())
66
- .filter(Boolean);
67
-
68
- const packageJsonPaths = stagedFiles.filter((p) => p.endsWith("package.json"));
69
- if (packageJsonPaths.length === 0) {
70
- out("No staged package.json changes found.");
71
- process.exit(0);
72
- }
73
-
74
- const updates = [];
75
-
76
- for (const path of packageJsonPaths) {
77
- const stagedPkg = readStagedFile(path);
78
- const headPkg = readHeadFile(path) || {};
79
- if (!stagedPkg) continue;
80
-
81
- const before = collectDeps(headPkg);
82
- const after = collectDeps(stagedPkg);
83
- const keys = new Set([...Object.keys(before), ...Object.keys(after)]);
84
-
85
- for (const name of keys) {
86
- const oldV = normalize(before[name]);
87
- const newV = normalize(after[name]);
88
- if (oldV && newV && oldV !== newV) {
89
- updates.push({ name, from: oldV, to: newV, path });
90
- }
91
- }
92
- }
93
-
94
- if (updates.length === 0) {
95
- out("No staged dependency version changes found in package.json.");
96
- process.exit(0);
97
- }
98
-
99
- out("Detected staged dependency updates:\n");
100
- for (const u of updates) {
101
- out(`- ${u.name}: ${u.from} -> ${u.to} (${u.path})`);
102
- }
103
-
104
- const commitMessage =
105
- updates.length === 1
106
- ? `vuln(${updates[0].name}@${semverFrom(updates[0].from) || updates[0].from}): bump to ${semverFrom(updates[0].to) || updates[0].to}`
107
- : "vuln(): updated dependencies";
108
- const commitBody =
109
- updates.length > 1
110
- ? `updated dependencies\n${updates.map((u) => `- ${u.name}: ${u.from} -> ${u.to}`).join("\n")}`
111
- : "";
112
-
113
- const hasStagedChanges = run("git diff --cached --name-only");
114
- if (!hasStagedChanges) {
115
- out("\nNo staged changes to commit.");
116
- process.exit(1);
117
- }
118
-
119
- const escapedMessage = commitMessage.replace(/"/g, '\\"');
120
- const escapedBody = commitBody.replace(/"/g, '\\"');
121
- const commitCommand = commitBody
122
- ? `git commit -m "${escapedMessage}" -m "${escapedBody}"`
123
- : `git commit -m "${escapedMessage}"`;
124
-
125
- out(`\nCreating commit:\n${commitMessage}\n`);
126
- runOrThrow(commitCommand);
127
- }
128
-
129
- main();