devextreme-cli 1.8.0 → 1.9.0
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 +5 -5
- package/src/applications/application.react.js +4 -3
- package/src/templates/cra-template/LICENSE +21 -0
- package/src/templates/cra-template/README.md +10 -0
- package/src/templates/cra-template/package.json +26 -0
- package/src/templates/cra-template/template/README.md +70 -0
- package/src/templates/cra-template/template/gitignore +23 -0
- package/src/templates/cra-template/template/public/favicon.ico +0 -0
- package/src/templates/cra-template/template/public/index.html +43 -0
- package/src/templates/cra-template/template/public/logo192.png +0 -0
- package/src/templates/cra-template/template/public/logo512.png +0 -0
- package/src/templates/cra-template/template/public/manifest.json +25 -0
- package/src/templates/cra-template/template/public/robots.txt +3 -0
- package/src/templates/cra-template/template/src/App.css +38 -0
- package/src/templates/cra-template/template/src/App.js +25 -0
- package/src/templates/cra-template/template/src/App.test.js +9 -0
- package/src/templates/cra-template/template/src/index.css +12 -0
- package/src/templates/cra-template/template/src/index.js +17 -0
- package/src/templates/cra-template/template/src/logo.svg +1 -0
- package/src/templates/cra-template/template/src/reportWebVitals.js +13 -0
- package/src/templates/cra-template/template/src/setupTests.js +5 -0
- package/src/templates/cra-template/template.json +14 -0
- package/src/templates/cra-template-typescript/LICENSE +21 -0
- package/src/templates/cra-template-typescript/README.md +20 -0
- package/src/templates/cra-template-typescript/package.json +27 -0
- package/src/templates/cra-template-typescript/template/README.md +46 -0
- package/src/templates/cra-template-typescript/template/gitignore +23 -0
- package/src/templates/cra-template-typescript/template/public/favicon.ico +0 -0
- package/src/templates/cra-template-typescript/template/public/index.html +43 -0
- package/src/templates/cra-template-typescript/template/public/logo192.png +0 -0
- package/src/templates/cra-template-typescript/template/public/logo512.png +0 -0
- package/src/templates/cra-template-typescript/template/public/manifest.json +25 -0
- package/src/templates/cra-template-typescript/template/public/robots.txt +3 -0
- package/src/templates/cra-template-typescript/template/src/App.css +38 -0
- package/src/templates/cra-template-typescript/template/src/App.test.tsx +10 -0
- package/src/templates/cra-template-typescript/template/src/App.tsx +26 -0
- package/src/templates/cra-template-typescript/template/src/index.css +12 -0
- package/src/templates/cra-template-typescript/template/src/index.tsx +19 -0
- package/src/templates/cra-template-typescript/template/src/logo.svg +1 -0
- package/src/templates/cra-template-typescript/template/src/reportWebVitals.ts +13 -0
- package/src/templates/cra-template-typescript/template/src/setupTests.ts +5 -0
- package/src/templates/cra-template-typescript/template.json +19 -0
- package/src/templates/react/application/src/App.test.tsx +2 -1
- package/src/templates/react/application/src/components/create-account-form/CreateAccountForm.scss +4 -3
- package/src/templates/react/application/src/components/create-account-form/CreateAccountForm.tsx +3 -5
- package/src/templates/react/application/src/components/header/Header.scss +1 -1
- package/src/templates/react/application/src/components/login-form/LoginForm.scss +2 -6
- package/src/templates/react/application/src/components/login-form/LoginForm.tsx +10 -12
- package/src/templates/react/application/src/components/reset-password-form/ResetPasswordForm.scss +3 -2
- package/src/templates/react/application/src/components/reset-password-form/ResetPasswordForm.tsx +3 -5
- package/src/templates/react/application/src/components/side-navigation-menu/SideNavigationMenu.scss +1 -1
- package/src/templates/react/application/src/components/side-navigation-menu/SideNavigationMenu.tsx +1 -1
- package/src/templates/react/application/src/components/theme-switcher/ThemeSwitcher.tsx +1 -1
- package/src/templates/react/application/src/dx-styles.scss +4 -3
- package/src/templates/react/application/src/layouts/single-card/single-card.scss +10 -5
- package/src/templates/react/application/src/theme.tsx +1 -1
- package/src/templates/react/application/src/variables.scss +32 -16
- package/src/templates/vue-v3/application/src/App.vue +1 -0
- package/src/templates/vue-v3/application/src/components/header-toolbar.vue +1 -1
- package/src/templates/vue-v3/application/src/components/side-nav-menu.vue +2 -2
- package/src/templates/vue-v3/application/src/dx-styles.scss +3 -3
- package/src/templates/vue-v3/application/src/layouts/single-card.vue +10 -5
- package/src/templates/vue-v3/application/src/variables.scss +30 -14
- package/src/templates/vue-v3/application/src/views/create-account-form.vue +21 -24
- package/src/templates/vue-v3/application/src/views/login-form.vue +18 -25
- package/src/templates/vue-v3/application/src/views/reset-password-form.vue +6 -9
- package/src/utility/latest-versions.js +3 -3
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"short_name": "React App",
|
|
3
|
+
"name": "Create React App Sample",
|
|
4
|
+
"icons": [
|
|
5
|
+
{
|
|
6
|
+
"src": "favicon.ico",
|
|
7
|
+
"sizes": "64x64 32x32 24x24 16x16",
|
|
8
|
+
"type": "image/x-icon"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"src": "logo192.png",
|
|
12
|
+
"type": "image/png",
|
|
13
|
+
"sizes": "192x192"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"src": "logo512.png",
|
|
17
|
+
"type": "image/png",
|
|
18
|
+
"sizes": "512x512"
|
|
19
|
+
}
|
|
20
|
+
],
|
|
21
|
+
"start_url": ".",
|
|
22
|
+
"display": "standalone",
|
|
23
|
+
"theme_color": "#000000",
|
|
24
|
+
"background_color": "#ffffff"
|
|
25
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
.App {
|
|
2
|
+
text-align: center;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.App-logo {
|
|
6
|
+
height: 40vmin;
|
|
7
|
+
pointer-events: none;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
11
|
+
.App-logo {
|
|
12
|
+
animation: App-logo-spin infinite 20s linear;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.App-header {
|
|
17
|
+
background-color: #282c34;
|
|
18
|
+
min-height: 100vh;
|
|
19
|
+
display: flex;
|
|
20
|
+
flex-direction: column;
|
|
21
|
+
align-items: center;
|
|
22
|
+
justify-content: center;
|
|
23
|
+
font-size: calc(10px + 2vmin);
|
|
24
|
+
color: white;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.App-link {
|
|
28
|
+
color: #61dafb;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
@keyframes App-logo-spin {
|
|
32
|
+
from {
|
|
33
|
+
transform: rotate(0deg);
|
|
34
|
+
}
|
|
35
|
+
to {
|
|
36
|
+
transform: rotate(360deg);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { render } from '@testing-library/react';
|
|
3
|
+
import { screen } from '@testing-library/dom';
|
|
4
|
+
import App from './App';
|
|
5
|
+
|
|
6
|
+
test('renders learn react link', () => {
|
|
7
|
+
render(<App />);
|
|
8
|
+
const linkElement = screen.getByText(/learn react/i);
|
|
9
|
+
expect(linkElement).toBeInTheDocument();
|
|
10
|
+
});
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import logo from './logo.svg';
|
|
3
|
+
import './App.css';
|
|
4
|
+
|
|
5
|
+
function App() {
|
|
6
|
+
return (
|
|
7
|
+
<div className="App">
|
|
8
|
+
<header className="App-header">
|
|
9
|
+
<img src={logo} className="App-logo" alt="logo" />
|
|
10
|
+
<p>
|
|
11
|
+
Edit <code>src/App.tsx</code> and save to reload.
|
|
12
|
+
</p>
|
|
13
|
+
<a
|
|
14
|
+
className="App-link"
|
|
15
|
+
href="https://reactjs.org"
|
|
16
|
+
target="_blank"
|
|
17
|
+
rel="noopener noreferrer"
|
|
18
|
+
>
|
|
19
|
+
Learn React
|
|
20
|
+
</a>
|
|
21
|
+
</header>
|
|
22
|
+
</div>
|
|
23
|
+
);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export default App;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
body {
|
|
2
|
+
margin: 0;
|
|
3
|
+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
|
|
4
|
+
'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
|
|
5
|
+
sans-serif;
|
|
6
|
+
-moz-osx-font-smoothing: grayscale;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
code {
|
|
10
|
+
font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
|
|
11
|
+
monospace;
|
|
12
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import ReactDOM from 'react-dom/client';
|
|
3
|
+
import './index.css';
|
|
4
|
+
import App from './App';
|
|
5
|
+
import reportWebVitals from './reportWebVitals';
|
|
6
|
+
|
|
7
|
+
const root = ReactDOM.createRoot(
|
|
8
|
+
document.getElementById('root') as HTMLElement
|
|
9
|
+
);
|
|
10
|
+
root.render(
|
|
11
|
+
<React.StrictMode>
|
|
12
|
+
<App />
|
|
13
|
+
</React.StrictMode>
|
|
14
|
+
);
|
|
15
|
+
|
|
16
|
+
// If you want to start measuring performance in your app, pass a function
|
|
17
|
+
// to log results (for example: reportWebVitals(console.log))
|
|
18
|
+
// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
|
|
19
|
+
reportWebVitals();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 841.9 595.3"><g fill="#61DAFB"><path d="M666.3 296.5c0-32.5-40.7-63.3-103.1-82.4 14.4-63.6 8-114.2-20.2-130.4-6.5-3.8-14.1-5.6-22.4-5.6v22.3c4.6 0 8.3.9 11.4 2.6 13.6 7.8 19.5 37.5 14.9 75.7-1.1 9.4-2.9 19.3-5.1 29.4-19.6-4.8-41-8.5-63.5-10.9-13.5-18.5-27.5-35.3-41.6-50 32.6-30.3 63.2-46.9 84-46.9V78c-27.5 0-63.5 19.6-99.9 53.6-36.4-33.8-72.4-53.2-99.9-53.2v22.3c20.7 0 51.4 16.5 84 46.6-14 14.7-28 31.4-41.3 49.9-22.6 2.4-44 6.1-63.6 11-2.3-10-4-19.7-5.2-29-4.7-38.2 1.1-67.9 14.6-75.8 3-1.8 6.9-2.6 11.5-2.6V78.5c-8.4 0-16 1.8-22.6 5.6-28.1 16.2-34.4 66.7-19.9 130.1-62.2 19.2-102.7 49.9-102.7 82.3 0 32.5 40.7 63.3 103.1 82.4-14.4 63.6-8 114.2 20.2 130.4 6.5 3.8 14.1 5.6 22.5 5.6 27.5 0 63.5-19.6 99.9-53.6 36.4 33.8 72.4 53.2 99.9 53.2 8.4 0 16-1.8 22.6-5.6 28.1-16.2 34.4-66.7 19.9-130.1 62-19.1 102.5-49.9 102.5-82.3zm-130.2-66.7c-3.7 12.9-8.3 26.2-13.5 39.5-4.1-8-8.4-16-13.1-24-4.6-8-9.5-15.8-14.4-23.4 14.2 2.1 27.9 4.7 41 7.9zm-45.8 106.5c-7.8 13.5-15.8 26.3-24.1 38.2-14.9 1.3-30 2-45.2 2-15.1 0-30.2-.7-45-1.9-8.3-11.9-16.4-24.6-24.2-38-7.6-13.1-14.5-26.4-20.8-39.8 6.2-13.4 13.2-26.8 20.7-39.9 7.8-13.5 15.8-26.3 24.1-38.2 14.9-1.3 30-2 45.2-2 15.1 0 30.2.7 45 1.9 8.3 11.9 16.4 24.6 24.2 38 7.6 13.1 14.5 26.4 20.8 39.8-6.3 13.4-13.2 26.8-20.7 39.9zm32.3-13c5.4 13.4 10 26.8 13.8 39.8-13.1 3.2-26.9 5.9-41.2 8 4.9-7.7 9.8-15.6 14.4-23.7 4.6-8 8.9-16.1 13-24.1zM421.2 430c-9.3-9.6-18.6-20.3-27.8-32 9 .4 18.2.7 27.5.7 9.4 0 18.7-.2 27.8-.7-9 11.7-18.3 22.4-27.5 32zm-74.4-58.9c-14.2-2.1-27.9-4.7-41-7.9 3.7-12.9 8.3-26.2 13.5-39.5 4.1 8 8.4 16 13.1 24 4.7 8 9.5 15.8 14.4 23.4zM420.7 163c9.3 9.6 18.6 20.3 27.8 32-9-.4-18.2-.7-27.5-.7-9.4 0-18.7.2-27.8.7 9-11.7 18.3-22.4 27.5-32zm-74 58.9c-4.9 7.7-9.8 15.6-14.4 23.7-4.6 8-8.9 16-13 24-5.4-13.4-10-26.8-13.8-39.8 13.1-3.1 26.9-5.8 41.2-7.9zm-90.5 125.2c-35.4-15.1-58.3-34.9-58.3-50.6 0-15.7 22.9-35.6 58.3-50.6 8.6-3.7 18-7 27.7-10.1 5.7 19.6 13.2 40 22.5 60.9-9.2 20.8-16.6 41.1-22.2 60.6-9.9-3.1-19.3-6.5-28-10.2zM310 490c-13.6-7.8-19.5-37.5-14.9-75.7 1.1-9.4 2.9-19.3 5.1-29.4 19.6 4.8 41 8.5 63.5 10.9 13.5 18.5 27.5 35.3 41.6 50-32.6 30.3-63.2 46.9-84 46.9-4.5-.1-8.3-1-11.3-2.7zm237.2-76.2c4.7 38.2-1.1 67.9-14.6 75.8-3 1.8-6.9 2.6-11.5 2.6-20.7 0-51.4-16.5-84-46.6 14-14.7 28-31.4 41.3-49.9 22.6-2.4 44-6.1 63.6-11 2.3 10.1 4.1 19.8 5.2 29.1zm38.5-66.7c-8.6 3.7-18 7-27.7 10.1-5.7-19.6-13.2-40-22.5-60.9 9.2-20.8 16.6-41.1 22.2-60.6 9.9 3.1 19.3 6.5 28.1 10.2 35.4 15.1 58.3 34.9 58.3 50.6-.1 15.7-23 35.6-58.4 50.6zM320.8 78.4z"/><circle cx="420.9" cy="296.5" r="45.7"/><path d="M520.5 78.1z"/></g></svg>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
const reportWebVitals = (onPerfEntry?: () => any) => {
|
|
2
|
+
if (onPerfEntry && onPerfEntry instanceof Function) {
|
|
3
|
+
import('web-vitals').then(({ onLCP, onINP, onCLS, onFCP, onTTFB }) => {
|
|
4
|
+
onCLS(onPerfEntry);
|
|
5
|
+
onINP(onPerfEntry);
|
|
6
|
+
onLCP(onPerfEntry);
|
|
7
|
+
onFCP(onPerfEntry);
|
|
8
|
+
onTTFB(onPerfEntry);
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export default reportWebVitals;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"package": {
|
|
3
|
+
"dependencies": {
|
|
4
|
+
"@testing-library/jest-dom": "^6.6.3",
|
|
5
|
+
"@testing-library/react": "^16.2.0",
|
|
6
|
+
"@testing-library/dom": "^10.4.0",
|
|
7
|
+
"@testing-library/user-event": "^14.6.0",
|
|
8
|
+
"@types/jest": "^29.5.14",
|
|
9
|
+
"@types/node": "^22.0.0",
|
|
10
|
+
"@types/react": "^19.0.0",
|
|
11
|
+
"@types/react-dom": "^19.0.0",
|
|
12
|
+
"typescript": "^4.0.0",
|
|
13
|
+
"web-vitals": "^4.2.4"
|
|
14
|
+
},
|
|
15
|
+
"eslintConfig": {
|
|
16
|
+
"extends": ["react-app", "react-app/jest"]
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
package/src/templates/react/application/src/components/create-account-form/CreateAccountForm.scss
CHANGED
|
@@ -2,9 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
.create-account-form {
|
|
4
4
|
.policy-info {
|
|
5
|
-
margin: 10px 0;
|
|
6
5
|
color: var(--base-text-color-alpha-7);
|
|
7
|
-
font-size:
|
|
6
|
+
font-size: 12px;
|
|
8
7
|
font-style: normal;
|
|
9
8
|
|
|
10
9
|
a {
|
|
@@ -14,7 +13,9 @@
|
|
|
14
13
|
|
|
15
14
|
.login-link {
|
|
16
15
|
color: var(--base-accent);
|
|
17
|
-
font-size:
|
|
16
|
+
font-size: 12px;
|
|
18
17
|
text-align: center;
|
|
18
|
+
padding: 6px 0 32px 0;
|
|
19
|
+
border-bottom: 1px solid var(--border-color);
|
|
19
20
|
}
|
|
20
21
|
}
|
package/src/templates/react/application/src/components/create-account-form/CreateAccountForm.tsx
CHANGED
|
@@ -92,12 +92,10 @@ export default function CreateAccountForm() {
|
|
|
92
92
|
</span>
|
|
93
93
|
</ButtonOptions>
|
|
94
94
|
</ButtonItem>
|
|
95
|
-
<Item>
|
|
96
|
-
<div className={'login-link'}>
|
|
97
|
-
Have an account? <Link to={'/login'}>Sign In</Link>
|
|
98
|
-
</div>
|
|
99
|
-
</Item>
|
|
100
95
|
</Form>
|
|
96
|
+
<div className={'login-link'}>
|
|
97
|
+
Have an account? <Link to={'/login'}>Sign In</Link>
|
|
98
|
+
</div>
|
|
101
99
|
</form>
|
|
102
100
|
);
|
|
103
101
|
}
|
|
@@ -3,16 +3,12 @@
|
|
|
3
3
|
.login-form {
|
|
4
4
|
.link {
|
|
5
5
|
text-align: center;
|
|
6
|
-
font-size:
|
|
6
|
+
font-size: 12px;
|
|
7
7
|
font-style: normal;
|
|
8
|
-
|
|
9
|
-
a {
|
|
10
|
-
text-decoration: none;
|
|
11
|
-
}
|
|
8
|
+
margin: 6px 0 50px;
|
|
12
9
|
}
|
|
13
10
|
|
|
14
11
|
.form-text {
|
|
15
|
-
margin: 10px 0;
|
|
16
12
|
color: var(--base-text-color-alpha-7);
|
|
17
13
|
}
|
|
18
14
|
}
|
|
@@ -9,6 +9,7 @@ import Form, {
|
|
|
9
9
|
EmailRule
|
|
10
10
|
} from 'devextreme-react/form';
|
|
11
11
|
import LoadIndicator from 'devextreme-react/load-indicator';
|
|
12
|
+
import Button from 'devextreme-react/button';
|
|
12
13
|
import notify from 'devextreme/ui/notify';
|
|
13
14
|
import { useAuth } from '../../contexts/auth';
|
|
14
15
|
|
|
@@ -78,19 +79,16 @@ export default function LoginForm() {
|
|
|
78
79
|
</span>
|
|
79
80
|
</ButtonOptions>
|
|
80
81
|
</ButtonItem>
|
|
81
|
-
<Item>
|
|
82
|
-
<div className={'link'}>
|
|
83
|
-
<Link to={'/reset-password'}>Forgot password?</Link>
|
|
84
|
-
</div>
|
|
85
|
-
</Item>
|
|
86
|
-
<ButtonItem>
|
|
87
|
-
<ButtonOptions
|
|
88
|
-
text={'Create an account'}
|
|
89
|
-
width={'100%'}
|
|
90
|
-
onClick={onCreateAccountClick}
|
|
91
|
-
/>
|
|
92
|
-
</ButtonItem>
|
|
93
82
|
</Form>
|
|
83
|
+
<div className={'link'}>
|
|
84
|
+
<Link to={'/reset-password'}>Forgot password?</Link>
|
|
85
|
+
</div>
|
|
86
|
+
<Button
|
|
87
|
+
text={'Create an account'}
|
|
88
|
+
stylingMode={ 'outlined' }
|
|
89
|
+
width={'100%'}
|
|
90
|
+
onClick={onCreateAccountClick}
|
|
91
|
+
/>
|
|
94
92
|
</form>
|
|
95
93
|
);
|
|
96
94
|
}
|
package/src/templates/react/application/src/components/reset-password-form/ResetPasswordForm.tsx
CHANGED
|
@@ -64,12 +64,10 @@ export default function ResetPasswordForm() {
|
|
|
64
64
|
</span>
|
|
65
65
|
</ButtonOptions>
|
|
66
66
|
</ButtonItem>
|
|
67
|
-
<Item>
|
|
68
|
-
<div className={'login-link'}>
|
|
69
|
-
Return to <Link to={'/login'}>Sign In</Link>
|
|
70
|
-
</div>
|
|
71
|
-
</Item>
|
|
72
67
|
</Form>
|
|
68
|
+
<div className={'login-link'}>
|
|
69
|
+
Return to <Link to={'/login'}>Sign In</Link>
|
|
70
|
+
</div>
|
|
73
71
|
</form>
|
|
74
72
|
);
|
|
75
73
|
}
|
package/src/templates/react/application/src/components/side-navigation-menu/SideNavigationMenu.tsx
CHANGED
|
@@ -35,7 +35,7 @@ export default function SideNavigationMenu(props<%=#isTypeScript%>: React.PropsW
|
|
|
35
35
|
const { navigationData: { currentPath } } = useNavigation();
|
|
36
36
|
|
|
37
37
|
const treeViewRef = useRef<%=#isTypeScript%><TreeViewRef><%=/isTypeScript%>(null);
|
|
38
|
-
const wrapperRef = useRef<%=#isTypeScript%><HTMLDivElement><%=/isTypeScript%>();
|
|
38
|
+
const wrapperRef = useRef<%=#isTypeScript%><HTMLDivElement><%=/isTypeScript%>(null);
|
|
39
39
|
const getWrapperRef = useCallback((element<%=#isTypeScript%>: HTMLDivElement<%=/isTypeScript%>) => {
|
|
40
40
|
const prevElement = wrapperRef.current;
|
|
41
41
|
if (prevElement) {
|
|
@@ -25,6 +25,7 @@ body {
|
|
|
25
25
|
display: flex;
|
|
26
26
|
height: 100%;
|
|
27
27
|
width: 100%;
|
|
28
|
+
min-width: 320px;
|
|
28
29
|
}
|
|
29
30
|
|
|
30
31
|
.content {
|
|
@@ -37,10 +38,10 @@ body {
|
|
|
37
38
|
margin: 0;
|
|
38
39
|
line-height: 40px;
|
|
39
40
|
}
|
|
41
|
+
}
|
|
40
42
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
}
|
|
43
|
+
.screen-x-small :not(.dx-card).content {
|
|
44
|
+
padding: 20px;
|
|
44
45
|
}
|
|
45
46
|
|
|
46
47
|
.container {
|
|
@@ -5,10 +5,11 @@
|
|
|
5
5
|
height: 100%;
|
|
6
6
|
|
|
7
7
|
.dx-card {
|
|
8
|
-
width:
|
|
8
|
+
width: 360px;
|
|
9
9
|
margin: auto auto;
|
|
10
|
-
padding:
|
|
10
|
+
padding: 24px;
|
|
11
11
|
flex-grow: 0;
|
|
12
|
+
border-radius: 8px;
|
|
12
13
|
|
|
13
14
|
.screen-x-small & {
|
|
14
15
|
width: 100%;
|
|
@@ -21,18 +22,22 @@
|
|
|
21
22
|
}
|
|
22
23
|
|
|
23
24
|
.header {
|
|
24
|
-
margin
|
|
25
|
+
margin: 24px 0;
|
|
25
26
|
|
|
26
27
|
.title {
|
|
27
28
|
color: var(--base-text-color);
|
|
28
|
-
line-height: 28px;
|
|
29
29
|
font-weight: 500;
|
|
30
30
|
font-size: 24px;
|
|
31
|
+
text-align: center;
|
|
32
|
+
line-height: 24px;
|
|
31
33
|
}
|
|
32
34
|
|
|
33
35
|
.description {
|
|
34
36
|
color: var(--base-text-color-alpha-7);
|
|
35
|
-
line-height:
|
|
37
|
+
line-height: 16px;
|
|
38
|
+
font-size: 12px;
|
|
39
|
+
margin-top: 32px;
|
|
40
|
+
text-align: center;
|
|
36
41
|
}
|
|
37
42
|
}
|
|
38
43
|
}
|
|
@@ -45,7 +45,7 @@ export function useThemeContext() {
|
|
|
45
45
|
document.body.classList.add(themeClassNamePrefix + theme);
|
|
46
46
|
}
|
|
47
47
|
|
|
48
|
-
return useMemo(()=> ({ theme, switchTheme, isDark }), [theme]);
|
|
48
|
+
return useMemo(()=> ({ theme, switchTheme, isDark }), [theme, switchTheme, isDark]);
|
|
49
49
|
}
|
|
50
50
|
|
|
51
51
|
export const ThemeContext = React.createContext<%=#isTypeScript%><ReturnType<typeof useThemeContext> | null><%=/isTypeScript%>(null);
|
|
@@ -1,14 +1,28 @@
|
|
|
1
|
+
@use 'sass:meta';
|
|
2
|
+
@use 'sass:color';
|
|
3
|
+
@use 'sass:map';
|
|
4
|
+
@use "./themes/generated/variables.base.scss" as variablesBase;
|
|
5
|
+
@use "./themes/generated/variables.base.dark.scss" as variablesBaseDark;
|
|
6
|
+
@use "./themes/generated/variables.additional.scss" as variablesAdditional;
|
|
7
|
+
@use "./themes/generated/variables.additional.dark.scss" as variablesAdditionalDark;
|
|
8
|
+
|
|
9
|
+
@mixin theme-variables($theme-name) {
|
|
10
|
+
$theme: meta.module-variables($theme-name);
|
|
11
|
+
$base-text-color: map.get($theme, 'base-text-color');
|
|
12
|
+
$base-bg: map.get($theme, 'base-bg');
|
|
13
|
+
|
|
14
|
+
--base-text-color: #{$base-text-color};
|
|
15
|
+
--base-bg: #{$base-bg};
|
|
16
|
+
--base-bg-darken-5: #{color.adjust($base-bg, $lightness: -5%)};
|
|
17
|
+
--base-accent: #{map.get($theme, 'base-accent')};
|
|
18
|
+
--base-text-color-alpha-7: #{rgba($base-text-color, color.alpha($base-text-color) * 0.7)};
|
|
19
|
+
}
|
|
20
|
+
|
|
1
21
|
:root {
|
|
2
|
-
|
|
3
|
-
@
|
|
4
|
-
|
|
5
|
-
--base-text-color: #{$base-text-color};
|
|
6
|
-
--base-bg: #{$base-bg};
|
|
7
|
-
--base-bg-darken-5: #{darken($base-bg, 5)};
|
|
8
|
-
--base-accent: #{$base-accent};
|
|
9
|
-
--base-text-color-alpha-7: #{rgba($base-text-color, alpha($base-text-color) * 0.7)};
|
|
10
|
-
--footer-border-color: rgba(224, 224, 224, 1);
|
|
22
|
+
body {
|
|
23
|
+
@include theme-variables('variablesBase');
|
|
11
24
|
|
|
25
|
+
--footer-border-color: rgba(224, 224, 224, 1);
|
|
12
26
|
--plus-icon-color: #242424;
|
|
13
27
|
--devextreme-logo-color: #596C7D;
|
|
14
28
|
--vue-logo-text-color: #35495E;
|
|
@@ -17,14 +31,12 @@
|
|
|
17
31
|
--shadow-color-second: rgba(0, 0, 0, 0.12);
|
|
18
32
|
}
|
|
19
33
|
|
|
20
|
-
.dx-swatch-
|
|
21
|
-
@
|
|
34
|
+
.dx-swatch-additional {
|
|
35
|
+
@include theme-variables('variablesAdditional');
|
|
36
|
+
}
|
|
22
37
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
--base-bg-darken-5: #{darken($base-bg, 5)};
|
|
26
|
-
--base-accent: #{$base-accent};
|
|
27
|
-
--base-text-color-alpha-7: #{rgba($base-text-color, alpha($base-text-color) * 0.7)};
|
|
38
|
+
.dx-swatch-dark {
|
|
39
|
+
@include theme-variables('variablesBaseDark');;
|
|
28
40
|
|
|
29
41
|
--plus-icon-color: #fff;
|
|
30
42
|
--devextreme-logo-color: #fff;
|
|
@@ -34,4 +46,8 @@
|
|
|
34
46
|
--shadow-color-second: rgba(0, 0, 0, 0.24);
|
|
35
47
|
--footer-border-color: rgba(97, 97, 97, 1);
|
|
36
48
|
}
|
|
49
|
+
|
|
50
|
+
.dx-swatch-additional-dark {
|
|
51
|
+
@include theme-variables('variablesAdditionalDark');
|
|
52
|
+
}
|
|
37
53
|
}
|
|
@@ -119,8 +119,8 @@ export default {
|
|
|
119
119
|
</script>
|
|
120
120
|
|
|
121
121
|
<style lang="scss">
|
|
122
|
-
@
|
|
123
|
-
@
|
|
122
|
+
@use "../variables.scss" as *;
|
|
123
|
+
@use "../dx-styles.scss" as *;
|
|
124
124
|
|
|
125
125
|
.dx-swatch-additional, .dx-swatch-additional-dark {
|
|
126
126
|
&.side-navigation-menu {
|
|
@@ -46,10 +46,11 @@ export default {
|
|
|
46
46
|
height: 100%;
|
|
47
47
|
|
|
48
48
|
.dx-card {
|
|
49
|
-
width:
|
|
49
|
+
width: 360px;
|
|
50
50
|
margin: auto auto;
|
|
51
|
-
padding:
|
|
51
|
+
padding: 24px;
|
|
52
52
|
flex-grow: 0;
|
|
53
|
+
border-radius: 8px;
|
|
53
54
|
|
|
54
55
|
.screen-x-small & {
|
|
55
56
|
width: 100%;
|
|
@@ -62,18 +63,22 @@ export default {
|
|
|
62
63
|
}
|
|
63
64
|
|
|
64
65
|
.header {
|
|
65
|
-
margin
|
|
66
|
+
margin: 24px 0;
|
|
66
67
|
|
|
67
68
|
.title {
|
|
68
69
|
color: var(--base-text-color);
|
|
69
|
-
|
|
70
|
+
text-align: center;
|
|
71
|
+
line-height: 24px;
|
|
70
72
|
font-weight: 500;
|
|
71
73
|
font-size: 24px;
|
|
72
74
|
}
|
|
73
75
|
|
|
74
76
|
.description {
|
|
75
77
|
color: var(--base-text-color-alpha-7);
|
|
76
|
-
line-height:
|
|
78
|
+
line-height: 16px;
|
|
79
|
+
font-size: 12px;
|
|
80
|
+
margin-top: 32px;
|
|
81
|
+
text-align: center;
|
|
77
82
|
}
|
|
78
83
|
}
|
|
79
84
|
}
|
|
@@ -1,14 +1,28 @@
|
|
|
1
|
+
@use 'sass:meta';
|
|
2
|
+
@use 'sass:color';
|
|
3
|
+
@use 'sass:map';
|
|
4
|
+
@use "./themes/generated/variables.base.scss" as variablesBase;
|
|
5
|
+
@use "./themes/generated/variables.base.dark.scss" as variablesBaseDark;
|
|
6
|
+
@use "./themes/generated/variables.additional.scss" as variablesAdditional;
|
|
7
|
+
@use "./themes/generated/variables.additional.dark.scss" as variablesAdditionalDark;
|
|
8
|
+
|
|
9
|
+
@mixin theme-variables($theme-name) {
|
|
10
|
+
$theme: meta.module-variables($theme-name);
|
|
11
|
+
$base-text-color: map.get($theme, 'base-text-color');
|
|
12
|
+
$base-bg: map.get($theme, 'base-bg');
|
|
13
|
+
|
|
14
|
+
--base-text-color: #{$base-text-color};
|
|
15
|
+
--base-bg: #{$base-bg};
|
|
16
|
+
--base-bg-darken-5: #{color.adjust($base-bg, $lightness: -5%)};
|
|
17
|
+
--base-accent: #{map.get($theme, 'base-accent')};
|
|
18
|
+
--base-text-color-alpha-7: #{rgba($base-text-color, color.alpha($base-text-color) * 0.7)};
|
|
19
|
+
}
|
|
20
|
+
|
|
1
21
|
:root {
|
|
2
22
|
body {
|
|
3
|
-
@
|
|
23
|
+
@include theme-variables('variablesBase');
|
|
4
24
|
|
|
5
|
-
--base-text-color: #{$base-text-color};
|
|
6
|
-
--base-bg: #{$base-bg};
|
|
7
|
-
--base-bg-darken-5: #{darken($base-bg, 5)};
|
|
8
|
-
--base-accent: #{$base-accent};
|
|
9
|
-
--base-text-color-alpha-7: #{rgba($base-text-color, alpha($base-text-color) * 0.7)};
|
|
10
25
|
--footer-border-color: rgba(224, 224, 224, 1);
|
|
11
|
-
|
|
12
26
|
--plus-icon-color: #242424;
|
|
13
27
|
--devextreme-logo-color: #596C7D;
|
|
14
28
|
--vue-logo-text-color: #35495E;
|
|
@@ -17,14 +31,12 @@
|
|
|
17
31
|
--shadow-color-second: rgba(0, 0, 0, 0.12);
|
|
18
32
|
}
|
|
19
33
|
|
|
20
|
-
.dx-swatch-
|
|
21
|
-
@
|
|
34
|
+
.dx-swatch-additional {
|
|
35
|
+
@include theme-variables('variablesAdditional');
|
|
36
|
+
}
|
|
22
37
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
--base-bg-darken-5: #{darken($base-bg, 5)};
|
|
26
|
-
--base-accent: #{$base-accent};
|
|
27
|
-
--base-text-color-alpha-7: #{rgba($base-text-color, alpha($base-text-color) * 0.7)};
|
|
38
|
+
.dx-swatch-dark {
|
|
39
|
+
@include theme-variables('variablesBaseDark');;
|
|
28
40
|
|
|
29
41
|
--plus-icon-color: #fff;
|
|
30
42
|
--devextreme-logo-color: #fff;
|
|
@@ -34,4 +46,8 @@
|
|
|
34
46
|
--shadow-color-second: rgba(0, 0, 0, 0.24);
|
|
35
47
|
--footer-border-color: rgba(97, 97, 97, 1);
|
|
36
48
|
}
|
|
49
|
+
|
|
50
|
+
.dx-swatch-additional-dark {
|
|
51
|
+
@include theme-variables('variablesAdditionalDark');
|
|
52
|
+
}
|
|
37
53
|
}
|