Skip to content

Commit 2df769d

Browse files
authored
feat!: transfer package from yandex-cloud (#331)
1 parent d399909 commit 2df769d

36 files changed

+518
-794
lines changed

.editorconfig

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,12 @@ end_of_line = lf
66
indent_size = 4
77
indent_style = space
88
insert_final_newline = true
9-
max_line_length = 120
9+
max_line_length = 100
1010
trim_trailing_whitespace = true
1111

12+
[{*.json, *.yaml, *.yml}]
13+
indent_size = 2
14+
1215
[*.md]
1316
max_line_length = 0
1417
trim_trailing_whitespace = false

.eslintrc

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,20 @@
11
{
2-
"extends": ["@yandex-cloud/eslint-config", "@yandex-cloud/eslint-config/prettier"],
2+
"extends": ["@gravity-ui/eslint-config", "@gravity-ui/eslint-config/prettier"],
33
"root": true,
44
"env": {
5-
"node": true
5+
"node": true,
6+
"jest": true
67
},
78
"overrides": [
89
{
910
"files": ["**/__tests__/**/*.[jt]s?(x)", "**/?(*.)+(spec|test).[jt]s?(x)"],
1011
"extends": ["plugin:testing-library/react"]
12+
},
13+
{
14+
"files": ["**/__stories__/**/*.[jt]s?(x)"],
15+
"rules": {
16+
"no-console": "off"
17+
}
1118
}
1219
]
1320
}

.github/workflows/main-preview.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,10 @@ jobs:
2323
- name: Build Storybook
2424
run: npx build-storybook
2525
shell: bash
26+
env:
27+
TS_NODE_PROJECT: .storybook/tsconfig.json
2628
- name: Upload to S3
27-
uses: yandex-cloud/ui-preview-upload-to-s3-action@main
29+
uses: gravity-ui/preview-upload-to-s3-action@v1
2830
with:
2931
src-path: storybook-static
3032
dest-path: /uikit/main/

.github/workflows/pr-preview-build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ jobs:
88
name: Build
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: yandex-cloud/ui-preview-build-action@main
11+
- uses: gravity-ui/preview-build-action@v1
1212
env:
1313
TS_NODE_PROJECT: .storybook/tsconfig.json

.github/workflows/pr-preview-deploy.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ jobs:
1414
github.event.workflow_run.conclusion == 'success'
1515
runs-on: ubuntu-latest
1616
steps:
17-
- uses: yandex-cloud/ui-preview-deploy-action@main
17+
- uses: gravity-ui/preview-deploy-action@v1
1818
with:
1919
project: uikit
20-
github-token: ${{ secrets.YC_UI_BOT_GITHUB_TOKEN }}
20+
github-token: ${{ secrets.GRAVITY_UI_BOT_GITHUB_TOKEN }}
2121
s3-key-id: ${{ secrets.STORYBOOK_S3_KEY_ID }}
2222
s3-secret-key: ${{ secrets.STORYBOOK_S3_SECRET_KEY }}

.github/workflows/release.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ jobs:
88
release:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: yandex-cloud/ui-release-action@main
12-
with:
13-
github-token: ${{ secrets.YC_UI_BOT_GITHUB_TOKEN }}
14-
npm-token: ${{ secrets.YC_UI_BOT_NPM_TOKEN }}
15-
node-version: 14
11+
- uses: gravity-ui/release-action@v1
12+
with:
13+
github-token: ${{ secrets.GRAVITY_UI_BOT_GITHUB_TOKEN }}
14+
npm-token: ${{ secrets.GRAVITY_UI_BOT_NPM_TOKEN }}
15+
node-version: 14

.husky/commit-msg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/bin/sh
22
. "$(dirname "$0")/_/husky.sh"
33

4-
npx commitlint --edit $1
4+
npx commitlint -e

.prettierrc.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
module.exports = require('@yandex-cloud/prettier-config');
1+
module.exports = require('@gravity-ui/prettier-config');

.storybook/theme.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,14 @@ export const CloudThemeLight = create({
2626
inputTextColor: 'black',
2727
inputBorderRadius: 4,
2828

29-
brandUrl: 'https://github.com/yandex-cloud/uikit',
30-
brandTitle: `<div style="font-size: 18px; color: #027bf3; font-weight: 600; margin-top: -6px; margin-bottom: 2px;">UIKit</div>
31-
<div style="font-size: 14px;color: #7d7d7d;font-weight: 400;">Yandex.Cloud Components</div>`,
29+
brandUrl: 'https://github.com/gravity-ui/uikit',
30+
brandTitle: `<div style="font-size: 18px; color: #027bf3; font-weight: 600; margin-top: -6px; margin-bottom: 2px;">Gravity UI</div>
31+
<div style="font-size: 14px;color: #7d7d7d;font-weight: 400;">Base Components</div>`,
3232
});
3333

3434
export const CloudThemeDark = create({
3535
base: 'dark',
36-
})
36+
});
3737

3838
export const themes = {
3939
light: CloudThemeLight,

.stylelintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"extends": ["@yandex-cloud/stylelint-config", "@yandex-cloud/stylelint-config/prettier"],
2+
"extends": ["@gravity-ui/stylelint-config", "@gravity-ui/stylelint-config/prettier"],
33
"rules": {
44
"declaration-colon-space-after": "always-single-line"
55
}

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,33 @@
1-
# @yandex-cloud/uikit &middot; [![npm package](https://img.shields.io/npm/v/@yandex-cloud/uikit)](https://www.npmjs.com/package/@yandex-cloud/uikit) [![CI](https://img.shields.io/github/workflow/status/yandex-cloud/uikit/CI/main?label=CI&logo=github)](https://github.com/yandex-cloud/uikit/actions/workflows/ci.yml?query=branch:main) [![storybook](https://img.shields.io/badge/Storybook-deployed-ff4685)](https://preview.yandexcloud.dev/uikit/)
1+
# @gravity-ui/uikit &middot; [![npm package](https://img.shields.io/npm/v/@gravity-ui/uikit)](https://www.npmjs.com/package/@gravity-ui/uikit) [![CI](https://img.shields.io/github/workflow/status/gravity-ui/uikit/CI/main?label=CI&logo=github)](https://github.com/gravity-ui/uikit/actions/workflows/ci.yml?query=branch:main) [![storybook](https://img.shields.io/badge/Storybook-deployed-ff4685)](https://preview.yandexcloud.dev/uikit/)
22

33
A set of React components for building rich web applications.
44

55
## Install
66

77
```shell
8-
npm install --save-dev @yandex-cloud/uikit @yandex-cloud/i18n
8+
npm install --save-dev @gravity-ui/uikit
99
```
1010

1111
## Usage
1212

1313
```jsx
1414
import React from 'react';
15-
import {Button} from '@yandex-cloud/uikit';
15+
import {Button} from '@gravity-ui/uikit';
1616

1717
const SubmitButton = <Button view="action" size="l" />;
1818
```
1919

2020
## I18N
2121

22-
Some components contain prepared text. For changing language use `configure` function.
22+
Some components contain prepared text. For changing language use `configure` function. Default language is `en`.
2323

2424
**index.js**
2525

2626
```js
27-
import {configure} from '@yandex-cloud/uikit';
27+
import {configure} from '@gravity-ui/uikit';
2828

2929
configure({
30-
lang: 'en',
30+
lang: 'ru',
3131
});
3232
```
3333

commitlint.config.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
/* eslint-env node */
21
module.exports = {extends: ['@commitlint/config-conventional']};

jest.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ module.exports = {
55
transform: {
66
'^.+\\.[jt]sx?$': 'ts-jest',
77
},
8-
transformIgnorePatterns: ['node_modules/(?!(@yandex-cloud)/)'],
8+
transformIgnorePatterns: ['node_modules/(?!(@gravity-ui)/)'],
99
coverageDirectory: './coverage',
1010
collectCoverageFrom: [
1111
'src/**/*.{ts,tsx,js,jsx}',

0 commit comments

Comments
 (0)