@weavix/cli 0.4.0 → 0.5.1
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/README.md +2 -1
- package/build/index.js +3113 -1006
- package/build/templates/_external/npmrc.template +1 -0
- package/build/templates/{_shared/src/styles-360.scss → _external/src/styles.scss} +14 -16
- package/build/templates/_internal/npmrc.template +3 -0
- package/build/templates/{_shared/src/styles-gravity.scss → _internal/src/styles.scss} +32 -11
- package/build/templates/_internal/src/themes/yandex-cloud/_dark-hc.scss +328 -0
- package/build/templates/_internal/src/themes/yandex-cloud/_dark.scss +329 -0
- package/build/templates/_internal/src/themes/yandex-cloud/_light-hc.scss +321 -0
- package/build/templates/_internal/src/themes/yandex-cloud/_light.scss +323 -0
- package/build/templates/_internal/src/themes/yandex-cloud.scss +168 -0
- package/build/templates/_shared/AGENTS.md +53 -0
- package/build/templates/_shared/manifest.schema.json +255 -5
- package/build/templates/_shared/package.json +63 -65
- package/build/templates/_shared/proxy.ts +111 -0
- package/build/templates/_shared/src/main.tsx +2 -6
- package/build/templates/_shared/src/themes/yandex-360/_dark-hc.scss +296 -0
- package/build/templates/_shared/src/themes/yandex-360/_dark.scss +297 -0
- package/build/templates/_shared/src/themes/yandex-360/_light-hc.scss +289 -0
- package/build/templates/_shared/src/themes/yandex-360/_light.scss +291 -0
- package/build/templates/_shared/src/themes/yandex-360.scss +197 -0
- package/build/templates/_shared/src/themes/ys-text.scss +79 -0
- package/build/templates/_shared/vite.config.ts +5 -1
- package/build/templates/attachment.viewer.action/index.html +1 -1
- package/build/templates/attachment.viewer.action/src/App.tsx +14 -24
- package/build/templates/board.tab/index.html +14 -0
- package/build/templates/board.tab/src/App.tsx +27 -0
- package/build/templates/default/src/App.tsx +1 -1
- package/build/templates/goal.action/index.html +1 -1
- package/build/templates/goal.action/src/App.tsx +4 -16
- package/build/templates/goal.block/index.html +14 -0
- package/build/templates/goal.block/src/App.tsx +27 -0
- package/build/templates/goal.editor.action/index.html +14 -0
- package/build/templates/goal.editor.action/src/App.tsx +56 -0
- package/build/templates/goal.tab/index.html +14 -0
- package/build/templates/goal.tab/src/App.tsx +27 -0
- package/build/templates/issue.action/index.html +1 -1
- package/build/templates/issue.action/src/App.tsx +6 -13
- package/build/templates/issue.block/index.html +1 -1
- package/build/templates/issue.block/src/App.tsx +9 -18
- package/build/templates/issue.comment.action/src/App.tsx +5 -11
- package/build/templates/issue.editor.action/index.html +14 -0
- package/build/templates/issue.editor.action/src/App.tsx +56 -0
- package/build/templates/issue.tab/src/App.tsx +5 -12
- package/build/templates/navigation/src/App.tsx +2 -7
- package/build/templates/portfolio.action/index.html +1 -1
- package/build/templates/portfolio.action/src/App.tsx +4 -21
- package/build/templates/portfolio.block/index.html +14 -0
- package/build/templates/portfolio.block/src/App.tsx +27 -0
- package/build/templates/portfolio.editor.action/index.html +14 -0
- package/build/templates/portfolio.editor.action/src/App.tsx +56 -0
- package/build/templates/portfolio.tab/index.html +14 -0
- package/build/templates/portfolio.tab/src/App.tsx +27 -0
- package/build/templates/project.action/index.html +1 -1
- package/build/templates/project.action/src/App.tsx +4 -21
- package/build/templates/project.block/index.html +14 -0
- package/build/templates/project.block/src/App.tsx +27 -0
- package/build/templates/project.editor.action/index.html +14 -0
- package/build/templates/project.editor.action/src/App.tsx +56 -0
- package/build/templates/project.tab/index.html +14 -0
- package/build/templates/project.tab/src/App.tsx +27 -0
- package/build/templates/queue.action/index.html +14 -0
- package/build/templates/queue.action/src/App.tsx +29 -0
- package/build/templates/queue.tab/index.html +14 -0
- package/build/templates/queue.tab/src/App.tsx +29 -0
- package/build/templates/trigger.action/index.html +1 -1
- package/build/templates/trigger.action/src/App.tsx +15 -21
- package/package.json +3 -1
- package/build/templates/_shared/npmrc.template +0 -2
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
|
+
<meta name="description" content="Web site created using vite" />
|
|
7
|
+
<title>Project Tab Plugin</title>
|
|
8
|
+
</head>
|
|
9
|
+
<body class="g-root g-root_theme_dark">
|
|
10
|
+
<noscript>You need to enable JavaScript to run this app.</noscript>
|
|
11
|
+
<div id="root"></div>
|
|
12
|
+
<script type="module" src="/src/main.tsx"></script>
|
|
13
|
+
</body>
|
|
14
|
+
</html>
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Card, DefinitionList, ThemeProvider, Text as Typography } from '@gravity-ui/uikit';
|
|
2
|
+
import { useTrackerPluginContext } from '@weavix/tracker-plugin-sdk-react';
|
|
3
|
+
|
|
4
|
+
const App = () => {
|
|
5
|
+
const { theme, slotContext } = useTrackerPluginContext<'project.tab'>();
|
|
6
|
+
|
|
7
|
+
if (!slotContext) {
|
|
8
|
+
return null;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
return (
|
|
12
|
+
<ThemeProvider theme={theme}>
|
|
13
|
+
<div>
|
|
14
|
+
<Card style={{ padding: '20px' }}>
|
|
15
|
+
<Typography variant="header-1" as="div" style={{ marginBottom: '16px' }}>
|
|
16
|
+
Базовый контекст (contextLevel: basic)
|
|
17
|
+
</Typography>
|
|
18
|
+
<DefinitionList>
|
|
19
|
+
<DefinitionList.Item name="ID">{slotContext.entityId}</DefinitionList.Item>
|
|
20
|
+
</DefinitionList>
|
|
21
|
+
</Card>
|
|
22
|
+
</div>
|
|
23
|
+
</ThemeProvider>
|
|
24
|
+
);
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
export default App;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
|
+
<meta name="description" content="Web site created using vite" />
|
|
7
|
+
<title>Queue Action Plugin</title>
|
|
8
|
+
</head>
|
|
9
|
+
<body class="g-root g-root_theme_dark">
|
|
10
|
+
<noscript>You need to enable JavaScript to run this app.</noscript>
|
|
11
|
+
<div id="root"></div>
|
|
12
|
+
<script type="module" src="/src/main.tsx"></script>
|
|
13
|
+
</body>
|
|
14
|
+
</html>
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Card, DefinitionList, ThemeProvider, Text as Typography } from '@gravity-ui/uikit';
|
|
2
|
+
import { useTrackerPluginContext } from '@weavix/tracker-plugin-sdk-react';
|
|
3
|
+
|
|
4
|
+
const App = () => {
|
|
5
|
+
const { theme, slotContext } = useTrackerPluginContext<'queue.action'>();
|
|
6
|
+
|
|
7
|
+
if (!slotContext) {
|
|
8
|
+
return null;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
return (
|
|
12
|
+
<ThemeProvider theme={theme}>
|
|
13
|
+
<div>
|
|
14
|
+
<Card style={{ padding: '20px' }}>
|
|
15
|
+
<Typography variant="header-1" as="div" style={{ marginBottom: '16px' }}>
|
|
16
|
+
Базовый контекст (contextLevel: basic)
|
|
17
|
+
</Typography>
|
|
18
|
+
<DefinitionList>
|
|
19
|
+
<DefinitionList.Item name="Ключ очереди">
|
|
20
|
+
{slotContext.entityId}
|
|
21
|
+
</DefinitionList.Item>
|
|
22
|
+
</DefinitionList>
|
|
23
|
+
</Card>
|
|
24
|
+
</div>
|
|
25
|
+
</ThemeProvider>
|
|
26
|
+
);
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export default App;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
|
+
<meta name="description" content="Web site created using vite" />
|
|
7
|
+
<title>Queue Tab Plugin</title>
|
|
8
|
+
</head>
|
|
9
|
+
<body class="g-root g-root_theme_dark">
|
|
10
|
+
<noscript>You need to enable JavaScript to run this app.</noscript>
|
|
11
|
+
<div id="root"></div>
|
|
12
|
+
<script type="module" src="/src/main.tsx"></script>
|
|
13
|
+
</body>
|
|
14
|
+
</html>
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Card, DefinitionList, ThemeProvider, Text as Typography } from '@gravity-ui/uikit';
|
|
2
|
+
import { useTrackerPluginContext } from '@weavix/tracker-plugin-sdk-react';
|
|
3
|
+
|
|
4
|
+
const App = () => {
|
|
5
|
+
const { theme, slotContext } = useTrackerPluginContext<'queue.tab'>();
|
|
6
|
+
|
|
7
|
+
if (!slotContext) {
|
|
8
|
+
return null;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
return (
|
|
12
|
+
<ThemeProvider theme={theme}>
|
|
13
|
+
<div style={{ padding: '50px' }}>
|
|
14
|
+
<Card style={{ padding: '20px' }}>
|
|
15
|
+
<Typography variant="header-1" as="div" style={{ marginBottom: '16px' }}>
|
|
16
|
+
Базовый контекст (contextLevel: basic)
|
|
17
|
+
</Typography>
|
|
18
|
+
<DefinitionList>
|
|
19
|
+
<DefinitionList.Item name="Ключ очереди">
|
|
20
|
+
{slotContext.entityId}
|
|
21
|
+
</DefinitionList.Item>
|
|
22
|
+
</DefinitionList>
|
|
23
|
+
</Card>
|
|
24
|
+
</div>
|
|
25
|
+
</ThemeProvider>
|
|
26
|
+
);
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export default App;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<meta charset="utf-8" />
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
6
|
<meta name="description" content="Web site created using vite" />
|
|
7
|
-
<title>Trigger
|
|
7
|
+
<title>Trigger Action Plugin</title>
|
|
8
8
|
</head>
|
|
9
9
|
<body class="g-root g-root_theme_dark">
|
|
10
10
|
<noscript>You need to enable JavaScript to run this app.</noscript>
|
|
@@ -1,16 +1,10 @@
|
|
|
1
1
|
import { useEffect, useState } from 'react';
|
|
2
2
|
|
|
3
3
|
import { Card, Checkbox, DefinitionList, Text, TextInput, ThemeProvider } from '@gravity-ui/uikit';
|
|
4
|
-
import {
|
|
5
|
-
TriggerActionData,
|
|
6
|
-
useTrackerPluginContext,
|
|
7
|
-
} from '@yandex-data-ui/tracker-plugin-sdk-react';
|
|
8
|
-
import block from 'bem-cn-lite';
|
|
4
|
+
import { TriggerActionData, useTrackerPluginContext } from '@weavix/tracker-plugin-sdk-react';
|
|
9
5
|
|
|
10
6
|
import './App.scss';
|
|
11
7
|
|
|
12
|
-
const b = block('app');
|
|
13
|
-
|
|
14
8
|
const WEBHOOK_SITE_BASE = 'https://webhook.site';
|
|
15
9
|
|
|
16
10
|
const SLOT_LABELS: Record<string, string> = {
|
|
@@ -56,7 +50,7 @@ function parseBodyOptions(body: string | undefined): { addIssueKey: boolean; add
|
|
|
56
50
|
const App = () => {
|
|
57
51
|
const { theme, registerHandler, slot, slotContext } = useTrackerPluginContext<
|
|
58
52
|
'trigger.create.action' | 'trigger.edit.action'
|
|
59
|
-
>();
|
|
53
|
+
>('full');
|
|
60
54
|
|
|
61
55
|
const [webhookSiteId, setWebhookSiteId] = useState<string>('');
|
|
62
56
|
const [addIssueKey, setAddIssueKey] = useState<boolean>(true);
|
|
@@ -90,14 +84,14 @@ const App = () => {
|
|
|
90
84
|
|
|
91
85
|
return (
|
|
92
86
|
<ThemeProvider theme={theme}>
|
|
93
|
-
<div className=
|
|
94
|
-
<Text variant="header-1" className=
|
|
87
|
+
<div className="app__container">
|
|
88
|
+
<Text variant="header-1" className="app__slot-title">
|
|
95
89
|
{slotTitle}
|
|
96
90
|
</Text>
|
|
97
91
|
|
|
98
92
|
{slotContext && (
|
|
99
|
-
<Card className=
|
|
100
|
-
<Text variant="subheader-2" className=
|
|
93
|
+
<Card className="app__context-card">
|
|
94
|
+
<Text variant="subheader-2" className="app__context-title">
|
|
101
95
|
Контекст
|
|
102
96
|
</Text>
|
|
103
97
|
<DefinitionList>
|
|
@@ -108,8 +102,8 @@ const App = () => {
|
|
|
108
102
|
</Card>
|
|
109
103
|
)}
|
|
110
104
|
|
|
111
|
-
<div className=
|
|
112
|
-
<Text variant="subheader-1" className=
|
|
105
|
+
<div className="app__form-field">
|
|
106
|
+
<Text variant="subheader-1" className="app__field-label">
|
|
113
107
|
ID сайта на webhook.site
|
|
114
108
|
</Text>
|
|
115
109
|
<TextInput
|
|
@@ -120,11 +114,11 @@ const App = () => {
|
|
|
120
114
|
/>
|
|
121
115
|
</div>
|
|
122
116
|
|
|
123
|
-
<div className=
|
|
124
|
-
<Text variant="subheader-1" className=
|
|
117
|
+
<div className="app__form-field">
|
|
118
|
+
<Text variant="subheader-1" className="app__field-label">
|
|
125
119
|
Включить в тело запроса
|
|
126
120
|
</Text>
|
|
127
|
-
<div className=
|
|
121
|
+
<div className="app__checkboxes">
|
|
128
122
|
<Checkbox checked={addIssueKey} onUpdate={setAddIssueKey} size="l">
|
|
129
123
|
<Text>Добавить ключ задачи</Text>
|
|
130
124
|
</Checkbox>
|
|
@@ -132,16 +126,16 @@ const App = () => {
|
|
|
132
126
|
<Text>Добавить очередь</Text>
|
|
133
127
|
</Checkbox>
|
|
134
128
|
</div>
|
|
135
|
-
<Text variant="body-2" className=
|
|
129
|
+
<Text variant="body-2" className="app__body-preview">
|
|
136
130
|
Шаблон: {buildBodyFromOptions(addIssueKey, addQueue)}
|
|
137
131
|
</Text>
|
|
138
132
|
</div>
|
|
139
133
|
|
|
140
|
-
<div className=
|
|
141
|
-
<Text variant="subheader-1" className=
|
|
134
|
+
<div className="app__form-field">
|
|
135
|
+
<Text variant="subheader-1" className="app__field-label">
|
|
142
136
|
Текущая очередь
|
|
143
137
|
</Text>
|
|
144
|
-
<Text variant="body-2" className=
|
|
138
|
+
<Text variant="body-2" className="app__queue-value">
|
|
145
139
|
{String(slotContext?.queue ?? '—')}
|
|
146
140
|
</Text>
|
|
147
141
|
</div>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@weavix/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.1",
|
|
4
4
|
"description": "CLI to work with plugins of Yandex Tracker",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"bin": {
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
"@aws-sdk/client-s3": "3.972.0",
|
|
14
14
|
"@aws-sdk/lib-storage": "3.972.0",
|
|
15
15
|
"@inquirer/prompts": "8.2.0",
|
|
16
|
+
"@napi-rs/keyring": "^1.3.0",
|
|
16
17
|
"@types/archiver": "7.0.0",
|
|
17
18
|
"ajv": "8.17.1",
|
|
18
19
|
"ajv-formats": "3.0.1",
|
|
@@ -20,6 +21,7 @@
|
|
|
20
21
|
"commander": "14.0.3",
|
|
21
22
|
"execa": "9.6.1",
|
|
22
23
|
"form-data": "4.0.5",
|
|
24
|
+
"jszip": "^3.10.1",
|
|
23
25
|
"node-fetch": "3.3.2",
|
|
24
26
|
"picocolors": "1.1.1",
|
|
25
27
|
"tinyglobby": "0.2.15"
|