Skip to content

Commit

Permalink
fix: revert release, fix package (#920)
Browse files Browse the repository at this point in the history
Release-as: 6.6.0
  • Loading branch information
artemmufazalov authored Jun 14, 2024
1 parent 293cb7c commit 5d3a7c6
Show file tree
Hide file tree
Showing 13 changed files with 26 additions and 54 deletions.
17 changes: 0 additions & 17 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,5 @@
# Changelog

## [6.6.0](https://github.com/ydb-platform/ydb-embedded-ui/compare/v6.5.0...v6.6.0) (2024-06-14)


### Features

* @gravity-ui/websql-autocomplete -> 9.1.0, enable autocomplete by default ([#904](https://github.com/ydb-platform/ydb-embedded-ui/issues/904)) ([e71fad9](https://github.com/ydb-platform/ydb-embedded-ui/commit/e71fad97fe16ec56dd3ee14e2e1f9ac76eb1bed9))
* **Diagnostics:** add tablets tab to all entities with tablets ([#892](https://github.com/ydb-platform/ydb-embedded-ui/issues/892)) ([e94d53a](https://github.com/ydb-platform/ydb-embedded-ui/commit/e94d53a1fb293119dc3383add220da5f0cf601c3))
* **Overview:** add view info ([#912](https://github.com/ydb-platform/ydb-embedded-ui/issues/912)) ([02e0cd6](https://github.com/ydb-platform/ydb-embedded-ui/commit/02e0cd66739b442eed649c9edd257ac1de87dcae))
* **SchemaViewer:** refactor, add view schema ([#910](https://github.com/ydb-platform/ydb-embedded-ui/issues/910)) ([3a10460](https://github.com/ydb-platform/ydb-embedded-ui/commit/3a1046031b0ced98494c821b8dc5bf13b87081c4))
* **UserSettings:** display app version ([#889](https://github.com/ydb-platform/ydb-embedded-ui/issues/889)) ([e52639e](https://github.com/ydb-platform/ydb-embedded-ui/commit/e52639e84dc5e1ca2707bb38ed917cd613a9c395))


### Bug Fixes

* **AsyncReplication:** fix table styles ([#891](https://github.com/ydb-platform/ydb-embedded-ui/issues/891)) ([f879369](https://github.com/ydb-platform/ydb-embedded-ui/commit/f87936951e28e18823c8743b3634f6f7d0d18b55))
* **TenantOverview:** increase section margin ([#916](https://github.com/ydb-platform/ydb-embedded-ui/issues/916)) ([d8f97f0](https://github.com/ydb-platform/ydb-embedded-ui/commit/d8f97f0de7d452a5f741cca023e233968be97bfa))

## [6.5.0](https://github.com/ydb-platform/ydb-embedded-ui/compare/v6.4.0...v6.5.0) (2024-06-06)


Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "ydb-embedded-ui",
"version": "6.6.0",
"version": "6.5.0",
"files": [
"dist"
],
"main": "dist/lib.js",
"main": "dist/src/lib.js",
"repository": {
"type": "git",
"url": "git@github.com:ydb-platform/ydb-embedded-ui.git"
Expand Down Expand Up @@ -65,7 +65,7 @@
"lint:other": "npm run prettier -- --check",
"prettier": "prettier '**/*.{json,yaml,yml,md}'",
"unimported": "npx unimported --no-cache",
"package": "rm -rf dist && tsc -p tsconfig.package.json && copyfiles -u 1 'src/**/*.{css,scss,svg}' dist",
"package": "rm -rf dist && tsc -p tsconfig.package.json && copyfiles -u 1 'src/**/*.{css,scss,svg}' dist/src",
"test": "react-app-rewired test",
"eject": "react-scripts eject",
"prepublishOnly": "npm run package",
Expand Down
5 changes: 5 additions & 0 deletions src/containers/App/App.scss
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@ body,
:root {
--g-color-base-yellow-light: rgba(255, 199, 0, 0.15);
--g-color-base-yellow-medium: rgba(255, 219, 77, 0.4);

--tenant-object-info-max-value-width: 300px;
--diagnostics-section-title-margin: 20px;
--diagnostics-section-margin: 30px;
--diagnostics-section-table-width: 872px;
}

.g-root {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import {MonitoringButton} from '../../../components/MonitoringButton/MonitoringButton';
import type {ETenantType} from '../../../types/api/tenant';
import type {GetMonitoringLink} from '../../../utils/monitoring';
import type Tenant from '../../Tenant/Tenant';
import {useClusterData} from '../useClusterData';
Expand All @@ -15,7 +16,7 @@ export function ExtendedTenant({
const {additionalNodesProps, cluster, monitoring} = useClusterData();

const additionalTenantProps = {
getMonitoringLink: (dbName?: string, dbType?: string) => {
getMonitoringLink: (dbName?: string, dbType?: ETenantType) => {
if (monitoring && dbName && dbType && getMonitoringLink) {
const href = getMonitoringLink({
monitoring,
Expand Down
12 changes: 6 additions & 6 deletions src/containers/Tenant/utils/schema.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type {NavigationTreeNodeType} from 'ydb-ui-components';

import {EPathSubType, EPathType} from '../../../types/api/schema';
import {ETenantType} from '../../../types/api/tenant';
import type {ETenantType} from '../../../types/api/tenant';

// this file contains verbose mappings that are typed in a way that ensures
// correctness when a new node type or a new path type is added
Expand Down Expand Up @@ -89,11 +89,11 @@ export const mapPathTypeToEntityName = (
// ====================

const databaseTypeToDBName: Record<ETenantType, string | undefined> = {
[ETenantType.UnknownTenantType]: 'Database',
[ETenantType.Domain]: 'Cluster Root',
[ETenantType.Dedicated]: 'Dedicated Database',
[ETenantType.Shared]: 'Shared Database',
[ETenantType.Serverless]: 'Serverless Database',
UnknownTenantType: 'Database',
Domain: 'Cluster Root',
Dedicated: 'Dedicated Database',
Shared: 'Shared Database',
Serverless: 'Serverless Database',
};

export const mapDatabaseTypeToDBName = (type?: ETenantType) => type && databaseTypeToDBName[type];
Expand Down
1 change: 0 additions & 1 deletion src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import reportWebVitals from './reportWebVitals';
import {history, store} from './store/defaultStore';

import './styles/themes.scss';
import './styles/constants.scss';
import './index.css';

async function render() {
Expand Down
3 changes: 2 additions & 1 deletion src/lib.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export {setUserSettings} from './store/reducers/settings/settings';
export {componentsRegistry} from './components/ComponentsProvider/componentsRegistry';
export {useSetting, useTypedSelector} from './utils/hooks';
export {getMonitoringLink, getMonitoringClusterLink} from './utils/monitoring';
export {i18n, Lang} from './utils/i18n';
export {i18n, Lang, registerKeysets} from './utils/i18n';
export {toaster} from './utils/createToast';
export {cn} from './utils/cn';
export * from './utils/constants';
Expand All @@ -31,3 +31,4 @@ export type {
} from './containers/UserSettings/settings';
export type {SettingProps} from './containers/UserSettings/Setting';
export type {AsideNavigationProps} from './containers/AsideNavigation/AsideNavigation';
export type {GetMonitoringLink, GetMonitoringClusterLink} from './utils/monitoring';
9 changes: 0 additions & 9 deletions src/styles/constants.scss

This file was deleted.

8 changes: 1 addition & 7 deletions src/types/api/tenant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,13 +128,7 @@ export interface ControlPlane {
name?: string;
}

export enum ETenantType {
'UnknownTenantType' = 'UnknownTenantType',
'Domain' = 'Domain',
'Dedicated' = 'Dedicated',
'Shared' = 'Shared',
'Serverless' = 'Serverless',
}
export type ETenantType = 'UnknownTenantType' | 'Domain' | 'Dedicated' | 'Shared' | 'Serverless';

export enum State {
'STATE_UNSPECIFIED' = 'STATE_UNSPECIFIED',
Expand Down
2 changes: 1 addition & 1 deletion src/utils/__test__/monitoring.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe('getMonitoringLink', () => {
monitoring: solomonString,
clusterName: 'global',
dbName: 'database',
dbType: 'Database',
dbType: 'Dedicated',
}),
).toBe(
'https://monitoring.test.ai/projects/yc.ydb.ydbaas-cloud/dashboards/aol34hftdn7o4fls50sv?p.cluster=global&p.host=cluster&p.slot=static&p.database=database',
Expand Down
8 changes: 3 additions & 5 deletions src/utils/monitoring.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {ETenantType} from '../types/api/tenant';
import type {ETenantType} from '../types/api/tenant';

export type ParsedMonitoringData = {
monitoring_url: string;
Expand All @@ -16,7 +16,7 @@ export type ParsedMonitoringData = {
export interface GetMonitoringLinkProps {
monitoring: string;
dbName: string;
dbType: string;
dbType: ETenantType;
clusterName?: string;
}

Expand All @@ -41,9 +41,7 @@ export function getMonitoringLink({

if (!url.search) {
const dashboard =
dbType === ETenantType.Serverless
? data.serverless_dashboard
: data.dedicated_dashboard;
dbType === 'Serverless' ? data.serverless_dashboard : data.dedicated_dashboard;

url.pathname += `/${dashboard}`;
}
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@
"noEmit": false,
"importHelpers": true
},
"include": ["src/**/*"],
"include": ["src/**/*", "package.json"],
"exclude": ["src/setup*", "src/index.tsx", "**/__tests__", "**/tests"]
}

0 comments on commit 5d3a7c6

Please sign in to comment.