Skip to content

Commit

Permalink
chore: update dependencies (#39)
Browse files Browse the repository at this point in the history
  • Loading branch information
amje authored Nov 1, 2023
1 parent 257208e commit 417c8d9
Show file tree
Hide file tree
Showing 656 changed files with 15,707 additions and 15,094 deletions.
16 changes: 16 additions & 0 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"sourceType": "unambiguous",
"presets": [
[
"@babel/preset-env",
{
"targets": {
"chrome": 100
}
}
],
"@babel/preset-typescript",
"@babel/preset-react"
],
"plugins": []
}
16 changes: 8 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: '14.x'
cache: 'npm'
node-version: 18
cache: npm
- name: Install Packages
run: npm ci
- name: Lint Files
Expand All @@ -32,14 +32,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: '14.x'
cache: 'npm'
node-version: 18
cache: npm
- name: Install Packages
run: npm ci
- name: Unit Tests
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/main-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: 14
node-version: 18
- name: Install Packages
run: npm ci
shell: bash
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/pr-preview-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: gravity-ui/preview-build-action@v1
with:
node-version: 18
env:
TS_NODE_PROJECT: .storybook/tsconfig.json
1 change: 1 addition & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ jobs:
with:
github-token: ${{ secrets.GRAVITY_UI_BOT_GITHUB_TOKEN }}
npm-token: ${{ secrets.GRAVITY_UI_BOT_NPM_TOKEN }}
node-version: 18
8 changes: 4 additions & 4 deletions .github/workflows/sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: 14
cache: 'npm'
node-version: 18
cache: npm
- name: Install Packages
run: npm ci
- name: Download SVG Files
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
14
18
1 change: 1 addition & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
"@gravity-ui/prettier-config"
1 change: 0 additions & 1 deletion .prettierrc.js

This file was deleted.

8 changes: 6 additions & 2 deletions .storybook/main.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
import type {StorybookConfig} from '@storybook/core-common';
import type {StorybookConfig} from '@storybook/react-webpack5';

const config: StorybookConfig = {
framework: {
name: '@storybook/react-webpack5',
options: {fastRefresh: true},
},
stories: ['./**/*.stories.@(ts|tsx)'],
addons: [
{name: '@storybook/preset-scss', options: {rule: {sideEffects: true}}},
Expand All @@ -17,4 +21,4 @@ const config: StorybookConfig = {
],
};

module.exports = config;
export default config;
5 changes: 3 additions & 2 deletions .storybook/manager.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import {addons} from '@storybook/addons';
import {addons} from '@storybook/manager-api';
import {create} from '@storybook/theming';
import packageJson from '../package.json';

addons.setConfig({
showPanel: false,
Expand Down Expand Up @@ -30,7 +31,7 @@ addons.setConfig({
inputBorderRadius: 4,

brandTitle: `<div style="font-size: 18px; color: #027bf3; font-weight: 600; margin-top: -6px; margin-bottom: 2px;">Gravity UI</div>
<div style="font-size: 14px;color: #7d7d7d;font-weight: 400;">Icons</div>`,
<div style="font-size: 14px;color: #7d7d7d;font-weight: 400; white-space: nowrap">Icons v${packageJson.version}</div>`,
brandUrl: 'https://gravity-ui.com',
}),
});
2 changes: 2 additions & 0 deletions .storybook/preview-head.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
27 changes: 10 additions & 17 deletions .storybook/preview.tsx
Original file line number Diff line number Diff line change
@@ -1,29 +1,22 @@
// eslint-disable-next-line import/order
import '@gravity-ui/uikit/styles/fonts.css';
// eslint-disable-next-line import/order
import '@gravity-ui/uikit/styles/styles.css';

import React from 'react';
import type {DecoratorFn} from '@storybook/react';
import type {Decorator, Preview} from '@storybook/react';
import {ThemeProvider} from '@gravity-ui/uikit';

const withThemeProvider: DecoratorFn = (Story, context) => {
const withThemeProvider: Decorator = (Story, context) => {
return (
<ThemeProvider theme={context.globals.theme}>
<ThemeProvider theme="light">
<Story {...context} />
</ThemeProvider>
);
};

export const decorators = [withThemeProvider];

export const globalTypes = {
theme: {
name: 'Theme',
defaultValue: 'light',
toolbar: {
icon: 'mirror',
items: [
{value: 'light', right: '☼', title: 'Light'},
{value: 'dark', right: '☾', title: 'Dark'},
],
},
},
const preview: Preview = {
decorators: [withThemeProvider],
};

export default preview;
4 changes: 2 additions & 2 deletions .storybook/src/IconTooltip/IconTooltip.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from 'react';
import {cn} from '../cn';
import {Popover, PopoverInstanceProps, Label} from '@gravity-ui/uikit';
import {Label, Popover, PopoverInstanceProps} from '@gravity-ui/uikit';

import './IconTooltip.scss';

Expand All @@ -21,7 +21,7 @@ export function IconTooltip({
forceOpen,
children,
}: IconTooltipProps) {
const popoverRef = React.useRef<PopoverInstanceProps>();
const popoverRef = React.useRef<PopoverInstanceProps>(null);
const content = React.useMemo(
() => (
<div className={b('grid')}>
Expand Down
6 changes: 3 additions & 3 deletions .storybook/src/Showcase.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from 'react';
import {cn} from './cn';
import {Meta, Story} from '@storybook/react';
import {Meta, StoryFn} from '@storybook/react';
import {Button, Icon as IconWrapper} from '@gravity-ui/uikit';
import {IconTooltip} from './IconTooltip/IconTooltip';
import metadata from '../../metadata.json';
Expand All @@ -27,10 +27,10 @@ const iconsMetadataByName = (metadata.icons as IconMeta[]).reduce(
{} as Record<string, IconMeta>,
);

export const Showcase: Story = () => {
export const Showcase: StoryFn = () => {
const [search, setSearch] = React.useState('');
const items = libContext.keys().map((path) => {
const module = libContext(path);
const module = libContext(path) as any;

Check warning on line 33 in .storybook/src/Showcase.stories.tsx

View workflow job for this annotation

GitHub Actions / Verify Files

Unexpected any. Specify a different type
const Icon = module.default || module;
const name = path.match(/(\w+)\.tsx$/)?.[1] ?? '';
const meta = iconsMetadataByName[name];
Expand Down
7 changes: 4 additions & 3 deletions .storybook/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@
"extends": "..",
"compilerOptions": {
"module": "commonjs",
"target": "ES2017",
"resolveJsonModule": true
"target": "ES2017"
},
"include": [
"src"
"src",
"../node_modules/webpack/module.d.ts",
"../package.json"
]
}
2 changes: 1 addition & 1 deletion commitlint.config.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = {extends: ['@commitlint/config-conventional']};
export default {extends: ['@commitlint/config-conventional']};
2 changes: 1 addition & 1 deletion lib/AbbrApi.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const AbbrApi = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/AbbrMl.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const AbbrMl = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/AbbrQl.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const AbbrQl = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/AbbrSql.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const AbbrSql = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/AbbrZip.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const AbbrZip = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/AntennaSignal.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const AntennaSignal = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/Aperture.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const Aperture = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/Archive.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const Archive = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowDown.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowDown = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowDownFromLine.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowDownFromLine = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowDownToLine.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowDownToLine = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowDownToSquare.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowDownToSquare = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowLeft.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowLeft = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowLeftFromLine.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowLeftFromLine = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowLeftToLine.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowLeftToLine = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowRight.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowRight = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowRightArrowLeft.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowRightArrowLeft = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowRightFromLine.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowRightFromLine = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowRightFromSquare.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowRightFromSquare = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowRightToLine.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowRightToLine = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowRightToSquare.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowRightToSquare = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
2 changes: 1 addition & 1 deletion lib/ArrowRotateLeft.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import {SVGProps} from 'react';
import type {SVGProps} from 'react';
const ArrowRotateLeft = (props: SVGProps<SVGSVGElement>) => (
<svg
xmlns="http://www.w3.org/2000/svg"
Expand Down
Loading

0 comments on commit 417c8d9

Please sign in to comment.