tsoft-cli 3.4.2 → 3.4.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/CHANGELOG.md +9 -0
- package/locales/en.json +4 -1
- package/locales/tr.json +4 -1
- package/package.json +1 -1
- package/src/commands/theme.js +6 -1
- package/src/ui/prompt-wrapper.js +18 -8
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,15 @@ All notable changes to T-Soft CLI will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [3.4.3] - 2026-04-08
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
- Login check before theme create — no more crash when not logged in
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
- Confirm prompts now use Evet/Hayır select instead of y/N
|
|
15
|
+
- "Minimal tema" renamed to "Starter tema"
|
|
16
|
+
|
|
8
17
|
## [3.4.2] - 2026-04-08
|
|
9
18
|
|
|
10
19
|
### Fixed
|
package/locales/en.json
CHANGED
|
@@ -9,6 +9,8 @@
|
|
|
9
9
|
"ui.label.theme_selection": "🎨 Theme Selection",
|
|
10
10
|
"ui.label.loading": "⏳ Processing",
|
|
11
11
|
"ui.prompt.continue": "Do you want to continue?",
|
|
12
|
+
"ui.label.yes": "Yes",
|
|
13
|
+
"ui.label.no": "No",
|
|
12
14
|
"ui.label.disabled": "(Disabled)",
|
|
13
15
|
|
|
14
16
|
"error.push.pending_review.message": "Cannot push: theme is pending review.",
|
|
@@ -87,12 +89,13 @@
|
|
|
87
89
|
"theme.no_themes": "⚠️ No themes found yet.",
|
|
88
90
|
"theme.count": "Total {{count}} themes found:",
|
|
89
91
|
"theme.folder_label": "Folder:",
|
|
92
|
+
"theme.login_required": "You must log in first. Run: tsoft login",
|
|
90
93
|
"theme.creating": "🎨 Creating new theme...",
|
|
91
94
|
"theme.name_prompt": "Theme Name:",
|
|
92
95
|
"theme.name_required": "Theme name cannot be empty",
|
|
93
96
|
"theme.description_prompt": "Description:",
|
|
94
97
|
"theme.author_prompt": "Developer:",
|
|
95
|
-
"theme.minimal_prompt": "
|
|
98
|
+
"theme.minimal_prompt": "Start with a starter theme?\n\nStarter theme includes only basic blocks, suitable for building from scratch.",
|
|
96
99
|
"theme.minimal_title": "🎨 Theme Type",
|
|
97
100
|
"theme.dir_exists_title": "⚠️ Directory Exists",
|
|
98
101
|
"theme.dir_exists_prompt": "Directory already exists!\n\nLocation: {{path}}\n\nOverwrite?",
|
package/locales/tr.json
CHANGED
|
@@ -9,6 +9,8 @@
|
|
|
9
9
|
"ui.label.theme_selection": "🎨 Tema Seçimi",
|
|
10
10
|
"ui.label.loading": "⏳ İşlem Devam Ediyor",
|
|
11
11
|
"ui.prompt.continue": "Devam etmek istiyor musunuz?",
|
|
12
|
+
"ui.label.yes": "Evet",
|
|
13
|
+
"ui.label.no": "Hayır",
|
|
12
14
|
"ui.label.disabled": "(Devre Dışı)",
|
|
13
15
|
|
|
14
16
|
"error.push.pending_review.message": "Push yapilamaz: tema inceleme bekliyor.",
|
|
@@ -87,12 +89,13 @@
|
|
|
87
89
|
"theme.no_themes": "⚠️ Henüz tema bulunmuyor.",
|
|
88
90
|
"theme.count": "Toplam {{count}} tema bulundu:",
|
|
89
91
|
"theme.folder_label": "Klasör:",
|
|
92
|
+
"theme.login_required": "Önce giriş yapmalısınız. Çalıştırın: tsoft login",
|
|
90
93
|
"theme.creating": "🎨 Yeni tema oluşturuluyor...",
|
|
91
94
|
"theme.name_prompt": "Tema Adı:",
|
|
92
95
|
"theme.name_required": "Tema adı boş olamaz",
|
|
93
96
|
"theme.description_prompt": "Açıklama:",
|
|
94
97
|
"theme.author_prompt": "Geliştirici:",
|
|
95
|
-
"theme.minimal_prompt": "
|
|
98
|
+
"theme.minimal_prompt": "Starter tema ile başlansın mı?\n\nStarter tema sadece temel blokları içerir, sıfırdan geliştirmeye uygundur.",
|
|
96
99
|
"theme.minimal_title": "🎨 Tema Tipi",
|
|
97
100
|
"theme.dir_exists_title": "⚠️ Dizin Mevcut",
|
|
98
101
|
"theme.dir_exists_prompt": "Dizin zaten mevcut!\n\nKonum: {{path}}\n\nÜzerine yazılsın mı?",
|
package/package.json
CHANGED
package/src/commands/theme.js
CHANGED
|
@@ -73,6 +73,12 @@ export async function themeListCommand() {
|
|
|
73
73
|
|
|
74
74
|
export async function themeCreateCommand() {
|
|
75
75
|
try {
|
|
76
|
+
const store = await getActiveStore();
|
|
77
|
+
if (!store) {
|
|
78
|
+
showWarning(t('theme.login_required'));
|
|
79
|
+
return;
|
|
80
|
+
}
|
|
81
|
+
|
|
76
82
|
console.log(chalk.cyan(t('theme.creating') + '\n'));
|
|
77
83
|
|
|
78
84
|
const name = await input({
|
|
@@ -98,7 +104,6 @@ export async function themeCreateCommand() {
|
|
|
98
104
|
}, t('theme.minimal_title'));
|
|
99
105
|
|
|
100
106
|
const themeSlug = slugify(name);
|
|
101
|
-
const store = await getActiveStore();
|
|
102
107
|
const storeSlug = normalizeStoreDomain(store);
|
|
103
108
|
const themePath = path.join(process.cwd(), storeSlug, themeSlug);
|
|
104
109
|
|
package/src/ui/prompt-wrapper.js
CHANGED
|
@@ -53,16 +53,26 @@ export function showBrandedBox(message, title = '', options = {}) {
|
|
|
53
53
|
* @param {string} boxTitle - Box başlığı
|
|
54
54
|
*/
|
|
55
55
|
export async function brandedConfirm(options, boxTitle = t('ui.label.confirm')) {
|
|
56
|
-
const {message, ...restOptions} = options;
|
|
57
|
-
|
|
58
|
-
//
|
|
59
|
-
|
|
56
|
+
const {message, default: defaultValue = false, ...restOptions} = options;
|
|
57
|
+
|
|
58
|
+
// message içinde \n\n varsa: ilk satır = prompt sorusu, kalan = box açıklaması
|
|
59
|
+
let promptMessage = message;
|
|
60
|
+
if (message.includes('\n\n')) {
|
|
61
|
+
const [question, ...descParts] = message.split('\n\n');
|
|
62
|
+
promptMessage = question;
|
|
63
|
+
showBrandedBox(descParts.join('\n\n'), boxTitle);
|
|
64
|
+
}
|
|
60
65
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
66
|
+
const answer = await inquirerSelect({
|
|
67
|
+
message: promptMessage,
|
|
68
|
+
choices: [
|
|
69
|
+
{ name: t('ui.label.yes'), value: true },
|
|
70
|
+
{ name: t('ui.label.no'), value: false },
|
|
71
|
+
],
|
|
72
|
+
default: defaultValue,
|
|
65
73
|
});
|
|
74
|
+
|
|
75
|
+
return answer;
|
|
66
76
|
}
|
|
67
77
|
|
|
68
78
|
/**
|