nocobase/packages/plugins/@nocobase/plugin-charts/src/client/ChartQueryBlockInitializer.tsx

157 lines
4.3 KiB
TypeScript
Raw Normal View History

feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
import { TableOutlined } from '@ant-design/icons';
feat: support custome themes (#2228) * feat: create custom-theme plugin * feat: add custom-theme * chore: add plugin name and description * chore: add deps * chore: optimize deps * refactor: rename * chore: add antd-token-previewer * chore: add deps in plugin * feat: add theme-editor * feat: add theme-editor * feat: add settings * feat: add theme collection * refactor: migration to the components folder * feat: add ThemeList * refactor: be better * feat: export createStyles * feat: implement ThemeCard (T-723) * style: optimize style * feat: add ThemeEditorProvider * feat: add ToEditTheme * chore: add isBuiltIn field * feat: implement WYSIWYG * refactor: migrate i18n * feat: support to save config * feat: add validation rule * refactor: remove useless code * refactor: optimize GlobalThemeProvider * feat: add CurrentUserSettingsMenuProvider * feat: support switching themes * refactor: migrate CurrentUserProvider to app root * feat: add InitializeTheme * fix: fix preview demo * fix: filter themes * fix: not valid when editing theme * fix: should restore the previous theme when closing theme editor * fix: fix algorithm * fix: the theme that was just saved should be applied * refactor: loacl antd-token-previewer * fix: should be based on the current theme when editing themes * feat: support to edit theme * perf: reduce executions * feat: add animation * fix: fix the type error of useRequest * feat: remove built-in themes * chore: reinstall deps * fix: fix version of deps * fix: delete client.d.ts to fix build error * chore: reinstall deps * fix: fix build * fix: fix build * fix: avoid build errors * fix: fix crashing * fix: use value instead of defaultValue * fix: avoid error * fix: avoid closure * fix: fix build * fix: fix style of login page * refactor(page): fix style * fix: fix style of PageHeader * refactor: fix style of Drawer * refactor: add FormDialog to loacl * refactor: fix style of SchemaSettings.ModalItem * refactor: fix style of pm/Card * fix: fix text color of pm/Marketplace * fix: fix table error * refactor: fix style of collection-manager/summary * refactor: fix style of fields drawer * chore: reinstall deps * fix: fix build * fix: fix build of custom-theme * fix: should export Plugin * refactor: fix style of GraphDrawPage * chore: upgrade plugin version * refactor: fix style of Modal by using antd App * refactor: fix style of FormDialog by using local version * refactor(workflow): refactor style using antd-style in workflow * fix(workflow): fix style of workflow * fix: fix size * refactor: add --nb-header-height * feat: remove theme configuration from system settings * refactor: migrate useUpdateThemeSettings to a new file * refactor: rename theme to themeId * feat: add updateSystemThemeSettings * refactor: migrate utils function * feat: use localStorage to avoid theme invalid in login page * fix: fix style of login page * fix: fix style of Drawer * feat: optimize style of theme card * fix: should use a empty object to reset theme * fix: fix test of Page * fix: fix test of Application * fix: change backgroundColor of login page * fix: fix all style of modal * fix: fix gap between blocks (T-896) * fix: fix color of font (T-905) * fix: fix build * fix: fix can not scroll in Drawer (T-897) * fix: fix width of built-in plugins page (T-900) * fix: fix style of import Modal (T-907) * fix: fix style of calendar (T-908) * fix: fix style of kanban (T-909) * fix: fix style of Gantt (T-910) * fix: fix style of Collapse (T-915) * fix: fix style of mobile (T-916) * fix: fix style of PageHeader (T-958) * fix: optimize background color of Drawer * fix: fix style of notification * fix: fix T-1000 * fix: fix style of LinkageHeader (T-1003) * fix: fix T-1004 * fix: fix style of scroll bar of chart (T-911) * fix: fix style of workflow drawer (T-997) * fix: fix T-922 * fix: fix T-924 * refactor: rename custom-theme to theme-editor * fix: fix T-999 * fix: fix T-1011 * fix: fix error * fix: optimize dark mode (T-921) * fix: fix style of markdown (T-1020) * fix: fix style of data template (T-1025) * fix: fix style of rich text (T-1026) * fix: fix style of a * fix: fix style of XButton (T-1028) * fix: fix T-1027 * fix: fix color of variable tag (T-1030) * chore: translation * feat: add a modal before create new theme (T-1024) * feat: highlight card when editing theme (T-1031) * feat: support to change theme name (T-1023) * fix: api.auth.getOption('theme') * fix: fix T-1032 * fix: fix feedback in feishu group * refactor: code review * fix: fix test * chore: rename * fix: useNotificationMiddleware * refactor: revert * fix: fix build * fix: notification * refactor: migrate CurrentUserProvider from Application to NocoBaseBuildInPlugin * fix: fix test * refactor: fix code review * chore: avoid test error --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-07-16 04:46:25 +00:00
import { FormLayout } from '@formily/antd-v5';
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
import { SchemaOptionsContext } from '@formily/react';
import {
feat: support custome themes (#2228) * feat: create custom-theme plugin * feat: add custom-theme * chore: add plugin name and description * chore: add deps * chore: optimize deps * refactor: rename * chore: add antd-token-previewer * chore: add deps in plugin * feat: add theme-editor * feat: add theme-editor * feat: add settings * feat: add theme collection * refactor: migration to the components folder * feat: add ThemeList * refactor: be better * feat: export createStyles * feat: implement ThemeCard (T-723) * style: optimize style * feat: add ThemeEditorProvider * feat: add ToEditTheme * chore: add isBuiltIn field * feat: implement WYSIWYG * refactor: migrate i18n * feat: support to save config * feat: add validation rule * refactor: remove useless code * refactor: optimize GlobalThemeProvider * feat: add CurrentUserSettingsMenuProvider * feat: support switching themes * refactor: migrate CurrentUserProvider to app root * feat: add InitializeTheme * fix: fix preview demo * fix: filter themes * fix: not valid when editing theme * fix: should restore the previous theme when closing theme editor * fix: fix algorithm * fix: the theme that was just saved should be applied * refactor: loacl antd-token-previewer * fix: should be based on the current theme when editing themes * feat: support to edit theme * perf: reduce executions * feat: add animation * fix: fix the type error of useRequest * feat: remove built-in themes * chore: reinstall deps * fix: fix version of deps * fix: delete client.d.ts to fix build error * chore: reinstall deps * fix: fix build * fix: fix build * fix: avoid build errors * fix: fix crashing * fix: use value instead of defaultValue * fix: avoid error * fix: avoid closure * fix: fix build * fix: fix style of login page * refactor(page): fix style * fix: fix style of PageHeader * refactor: fix style of Drawer * refactor: add FormDialog to loacl * refactor: fix style of SchemaSettings.ModalItem * refactor: fix style of pm/Card * fix: fix text color of pm/Marketplace * fix: fix table error * refactor: fix style of collection-manager/summary * refactor: fix style of fields drawer * chore: reinstall deps * fix: fix build * fix: fix build of custom-theme * fix: should export Plugin * refactor: fix style of GraphDrawPage * chore: upgrade plugin version * refactor: fix style of Modal by using antd App * refactor: fix style of FormDialog by using local version * refactor(workflow): refactor style using antd-style in workflow * fix(workflow): fix style of workflow * fix: fix size * refactor: add --nb-header-height * feat: remove theme configuration from system settings * refactor: migrate useUpdateThemeSettings to a new file * refactor: rename theme to themeId * feat: add updateSystemThemeSettings * refactor: migrate utils function * feat: use localStorage to avoid theme invalid in login page * fix: fix style of login page * fix: fix style of Drawer * feat: optimize style of theme card * fix: should use a empty object to reset theme * fix: fix test of Page * fix: fix test of Application * fix: change backgroundColor of login page * fix: fix all style of modal * fix: fix gap between blocks (T-896) * fix: fix color of font (T-905) * fix: fix build * fix: fix can not scroll in Drawer (T-897) * fix: fix width of built-in plugins page (T-900) * fix: fix style of import Modal (T-907) * fix: fix style of calendar (T-908) * fix: fix style of kanban (T-909) * fix: fix style of Gantt (T-910) * fix: fix style of Collapse (T-915) * fix: fix style of mobile (T-916) * fix: fix style of PageHeader (T-958) * fix: optimize background color of Drawer * fix: fix style of notification * fix: fix T-1000 * fix: fix style of LinkageHeader (T-1003) * fix: fix T-1004 * fix: fix style of scroll bar of chart (T-911) * fix: fix style of workflow drawer (T-997) * fix: fix T-922 * fix: fix T-924 * refactor: rename custom-theme to theme-editor * fix: fix T-999 * fix: fix T-1011 * fix: fix error * fix: optimize dark mode (T-921) * fix: fix style of markdown (T-1020) * fix: fix style of data template (T-1025) * fix: fix style of rich text (T-1026) * fix: fix style of a * fix: fix style of XButton (T-1028) * fix: fix T-1027 * fix: fix color of variable tag (T-1030) * chore: translation * feat: add a modal before create new theme (T-1024) * feat: highlight card when editing theme (T-1031) * feat: support to change theme name (T-1023) * fix: api.auth.getOption('theme') * fix: fix T-1032 * fix: fix feedback in feishu group * refactor: code review * fix: fix test * chore: rename * fix: useNotificationMiddleware * refactor: revert * fix: fix build * fix: notification * refactor: migrate CurrentUserProvider from Application to NocoBaseBuildInPlugin * fix: fix test * refactor: fix code review * chore: avoid test error --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-07-16 04:46:25 +00:00
FormDialog,
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
SchemaComponent,
SchemaComponentOptions,
SchemaInitializer,
SchemaInitializerButtonContext,
useAPIClient,
feat: support custome themes (#2228) * feat: create custom-theme plugin * feat: add custom-theme * chore: add plugin name and description * chore: add deps * chore: optimize deps * refactor: rename * chore: add antd-token-previewer * chore: add deps in plugin * feat: add theme-editor * feat: add theme-editor * feat: add settings * feat: add theme collection * refactor: migration to the components folder * feat: add ThemeList * refactor: be better * feat: export createStyles * feat: implement ThemeCard (T-723) * style: optimize style * feat: add ThemeEditorProvider * feat: add ToEditTheme * chore: add isBuiltIn field * feat: implement WYSIWYG * refactor: migrate i18n * feat: support to save config * feat: add validation rule * refactor: remove useless code * refactor: optimize GlobalThemeProvider * feat: add CurrentUserSettingsMenuProvider * feat: support switching themes * refactor: migrate CurrentUserProvider to app root * feat: add InitializeTheme * fix: fix preview demo * fix: filter themes * fix: not valid when editing theme * fix: should restore the previous theme when closing theme editor * fix: fix algorithm * fix: the theme that was just saved should be applied * refactor: loacl antd-token-previewer * fix: should be based on the current theme when editing themes * feat: support to edit theme * perf: reduce executions * feat: add animation * fix: fix the type error of useRequest * feat: remove built-in themes * chore: reinstall deps * fix: fix version of deps * fix: delete client.d.ts to fix build error * chore: reinstall deps * fix: fix build * fix: fix build * fix: avoid build errors * fix: fix crashing * fix: use value instead of defaultValue * fix: avoid error * fix: avoid closure * fix: fix build * fix: fix style of login page * refactor(page): fix style * fix: fix style of PageHeader * refactor: fix style of Drawer * refactor: add FormDialog to loacl * refactor: fix style of SchemaSettings.ModalItem * refactor: fix style of pm/Card * fix: fix text color of pm/Marketplace * fix: fix table error * refactor: fix style of collection-manager/summary * refactor: fix style of fields drawer * chore: reinstall deps * fix: fix build * fix: fix build of custom-theme * fix: should export Plugin * refactor: fix style of GraphDrawPage * chore: upgrade plugin version * refactor: fix style of Modal by using antd App * refactor: fix style of FormDialog by using local version * refactor(workflow): refactor style using antd-style in workflow * fix(workflow): fix style of workflow * fix: fix size * refactor: add --nb-header-height * feat: remove theme configuration from system settings * refactor: migrate useUpdateThemeSettings to a new file * refactor: rename theme to themeId * feat: add updateSystemThemeSettings * refactor: migrate utils function * feat: use localStorage to avoid theme invalid in login page * fix: fix style of login page * fix: fix style of Drawer * feat: optimize style of theme card * fix: should use a empty object to reset theme * fix: fix test of Page * fix: fix test of Application * fix: change backgroundColor of login page * fix: fix all style of modal * fix: fix gap between blocks (T-896) * fix: fix color of font (T-905) * fix: fix build * fix: fix can not scroll in Drawer (T-897) * fix: fix width of built-in plugins page (T-900) * fix: fix style of import Modal (T-907) * fix: fix style of calendar (T-908) * fix: fix style of kanban (T-909) * fix: fix style of Gantt (T-910) * fix: fix style of Collapse (T-915) * fix: fix style of mobile (T-916) * fix: fix style of PageHeader (T-958) * fix: optimize background color of Drawer * fix: fix style of notification * fix: fix T-1000 * fix: fix style of LinkageHeader (T-1003) * fix: fix T-1004 * fix: fix style of scroll bar of chart (T-911) * fix: fix style of workflow drawer (T-997) * fix: fix T-922 * fix: fix T-924 * refactor: rename custom-theme to theme-editor * fix: fix T-999 * fix: fix T-1011 * fix: fix error * fix: optimize dark mode (T-921) * fix: fix style of markdown (T-1020) * fix: fix style of data template (T-1025) * fix: fix style of rich text (T-1026) * fix: fix style of a * fix: fix style of XButton (T-1028) * fix: fix T-1027 * fix: fix color of variable tag (T-1030) * chore: translation * feat: add a modal before create new theme (T-1024) * feat: highlight card when editing theme (T-1031) * feat: support to change theme name (T-1023) * fix: api.auth.getOption('theme') * fix: fix T-1032 * fix: fix feedback in feishu group * refactor: code review * fix: fix test * chore: rename * fix: useNotificationMiddleware * refactor: revert * fix: fix build * fix: notification * refactor: migrate CurrentUserProvider from Application to NocoBaseBuildInPlugin * fix: fix test * refactor: fix code review * chore: avoid test error --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-07-16 04:46:25 +00:00
useGlobalTheme,
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
} from '@nocobase/client';
import { error } from '@nocobase/utils/client';
import React, { useCallback, useContext, useMemo } from 'react';
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
import { useChartQueryMetadataContext } from './ChartQueryMetadataProvider';
import { lang } from './locale';
import { getQueryTypeSchema } from './settings/queryTypes';
export interface ChartQueryMetadata {
id: number;
title: string;
type: string;
fields: { name: string }[];
}
export const ChartQueryBlockInitializer = (props) => {
const { templateWrap, onCreateBlockSchema, componentType, createBlockSchema, insert, ...others } = props;
const { setVisible } = useContext(SchemaInitializerButtonContext);
const apiClient = useAPIClient();
const ctx = useChartQueryMetadataContext();
const options = useContext(SchemaOptionsContext);
feat: support custome themes (#2228) * feat: create custom-theme plugin * feat: add custom-theme * chore: add plugin name and description * chore: add deps * chore: optimize deps * refactor: rename * chore: add antd-token-previewer * chore: add deps in plugin * feat: add theme-editor * feat: add theme-editor * feat: add settings * feat: add theme collection * refactor: migration to the components folder * feat: add ThemeList * refactor: be better * feat: export createStyles * feat: implement ThemeCard (T-723) * style: optimize style * feat: add ThemeEditorProvider * feat: add ToEditTheme * chore: add isBuiltIn field * feat: implement WYSIWYG * refactor: migrate i18n * feat: support to save config * feat: add validation rule * refactor: remove useless code * refactor: optimize GlobalThemeProvider * feat: add CurrentUserSettingsMenuProvider * feat: support switching themes * refactor: migrate CurrentUserProvider to app root * feat: add InitializeTheme * fix: fix preview demo * fix: filter themes * fix: not valid when editing theme * fix: should restore the previous theme when closing theme editor * fix: fix algorithm * fix: the theme that was just saved should be applied * refactor: loacl antd-token-previewer * fix: should be based on the current theme when editing themes * feat: support to edit theme * perf: reduce executions * feat: add animation * fix: fix the type error of useRequest * feat: remove built-in themes * chore: reinstall deps * fix: fix version of deps * fix: delete client.d.ts to fix build error * chore: reinstall deps * fix: fix build * fix: fix build * fix: avoid build errors * fix: fix crashing * fix: use value instead of defaultValue * fix: avoid error * fix: avoid closure * fix: fix build * fix: fix style of login page * refactor(page): fix style * fix: fix style of PageHeader * refactor: fix style of Drawer * refactor: add FormDialog to loacl * refactor: fix style of SchemaSettings.ModalItem * refactor: fix style of pm/Card * fix: fix text color of pm/Marketplace * fix: fix table error * refactor: fix style of collection-manager/summary * refactor: fix style of fields drawer * chore: reinstall deps * fix: fix build * fix: fix build of custom-theme * fix: should export Plugin * refactor: fix style of GraphDrawPage * chore: upgrade plugin version * refactor: fix style of Modal by using antd App * refactor: fix style of FormDialog by using local version * refactor(workflow): refactor style using antd-style in workflow * fix(workflow): fix style of workflow * fix: fix size * refactor: add --nb-header-height * feat: remove theme configuration from system settings * refactor: migrate useUpdateThemeSettings to a new file * refactor: rename theme to themeId * feat: add updateSystemThemeSettings * refactor: migrate utils function * feat: use localStorage to avoid theme invalid in login page * fix: fix style of login page * fix: fix style of Drawer * feat: optimize style of theme card * fix: should use a empty object to reset theme * fix: fix test of Page * fix: fix test of Application * fix: change backgroundColor of login page * fix: fix all style of modal * fix: fix gap between blocks (T-896) * fix: fix color of font (T-905) * fix: fix build * fix: fix can not scroll in Drawer (T-897) * fix: fix width of built-in plugins page (T-900) * fix: fix style of import Modal (T-907) * fix: fix style of calendar (T-908) * fix: fix style of kanban (T-909) * fix: fix style of Gantt (T-910) * fix: fix style of Collapse (T-915) * fix: fix style of mobile (T-916) * fix: fix style of PageHeader (T-958) * fix: optimize background color of Drawer * fix: fix style of notification * fix: fix T-1000 * fix: fix style of LinkageHeader (T-1003) * fix: fix T-1004 * fix: fix style of scroll bar of chart (T-911) * fix: fix style of workflow drawer (T-997) * fix: fix T-922 * fix: fix T-924 * refactor: rename custom-theme to theme-editor * fix: fix T-999 * fix: fix T-1011 * fix: fix error * fix: optimize dark mode (T-921) * fix: fix style of markdown (T-1020) * fix: fix style of data template (T-1025) * fix: fix style of rich text (T-1026) * fix: fix style of a * fix: fix style of XButton (T-1028) * fix: fix T-1027 * fix: fix color of variable tag (T-1030) * chore: translation * feat: add a modal before create new theme (T-1024) * feat: highlight card when editing theme (T-1031) * feat: support to change theme name (T-1023) * fix: api.auth.getOption('theme') * fix: fix T-1032 * fix: fix feedback in feishu group * refactor: code review * fix: fix test * chore: rename * fix: useNotificationMiddleware * refactor: revert * fix: fix build * fix: notification * refactor: migrate CurrentUserProvider from Application to NocoBaseBuildInPlugin * fix: fix test * refactor: fix code review * chore: avoid test error --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-07-16 04:46:25 +00:00
const { theme } = useGlobalTheme();
const onAddQuery = useCallback(
(info) => {
FormDialog(
{
sql: lang('Add SQL query'),
json: lang('Add JSON query'),
}[info.key],
() => {
return (
<div>
<SchemaComponentOptions scope={options.scope} components={{ ...options.components }}>
<FormLayout layout={'vertical'}>
<SchemaComponent
schema={{
type: 'object',
properties: {
title: {
title: lang('Title'),
required: true,
'x-component': 'Input',
'x-decorator': 'FormItem',
},
options: getQueryTypeSchema(info.key),
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
},
}}
/>
</FormLayout>
</SchemaComponentOptions>
</div>
);
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
},
feat: support custome themes (#2228) * feat: create custom-theme plugin * feat: add custom-theme * chore: add plugin name and description * chore: add deps * chore: optimize deps * refactor: rename * chore: add antd-token-previewer * chore: add deps in plugin * feat: add theme-editor * feat: add theme-editor * feat: add settings * feat: add theme collection * refactor: migration to the components folder * feat: add ThemeList * refactor: be better * feat: export createStyles * feat: implement ThemeCard (T-723) * style: optimize style * feat: add ThemeEditorProvider * feat: add ToEditTheme * chore: add isBuiltIn field * feat: implement WYSIWYG * refactor: migrate i18n * feat: support to save config * feat: add validation rule * refactor: remove useless code * refactor: optimize GlobalThemeProvider * feat: add CurrentUserSettingsMenuProvider * feat: support switching themes * refactor: migrate CurrentUserProvider to app root * feat: add InitializeTheme * fix: fix preview demo * fix: filter themes * fix: not valid when editing theme * fix: should restore the previous theme when closing theme editor * fix: fix algorithm * fix: the theme that was just saved should be applied * refactor: loacl antd-token-previewer * fix: should be based on the current theme when editing themes * feat: support to edit theme * perf: reduce executions * feat: add animation * fix: fix the type error of useRequest * feat: remove built-in themes * chore: reinstall deps * fix: fix version of deps * fix: delete client.d.ts to fix build error * chore: reinstall deps * fix: fix build * fix: fix build * fix: avoid build errors * fix: fix crashing * fix: use value instead of defaultValue * fix: avoid error * fix: avoid closure * fix: fix build * fix: fix style of login page * refactor(page): fix style * fix: fix style of PageHeader * refactor: fix style of Drawer * refactor: add FormDialog to loacl * refactor: fix style of SchemaSettings.ModalItem * refactor: fix style of pm/Card * fix: fix text color of pm/Marketplace * fix: fix table error * refactor: fix style of collection-manager/summary * refactor: fix style of fields drawer * chore: reinstall deps * fix: fix build * fix: fix build of custom-theme * fix: should export Plugin * refactor: fix style of GraphDrawPage * chore: upgrade plugin version * refactor: fix style of Modal by using antd App * refactor: fix style of FormDialog by using local version * refactor(workflow): refactor style using antd-style in workflow * fix(workflow): fix style of workflow * fix: fix size * refactor: add --nb-header-height * feat: remove theme configuration from system settings * refactor: migrate useUpdateThemeSettings to a new file * refactor: rename theme to themeId * feat: add updateSystemThemeSettings * refactor: migrate utils function * feat: use localStorage to avoid theme invalid in login page * fix: fix style of login page * fix: fix style of Drawer * feat: optimize style of theme card * fix: should use a empty object to reset theme * fix: fix test of Page * fix: fix test of Application * fix: change backgroundColor of login page * fix: fix all style of modal * fix: fix gap between blocks (T-896) * fix: fix color of font (T-905) * fix: fix build * fix: fix can not scroll in Drawer (T-897) * fix: fix width of built-in plugins page (T-900) * fix: fix style of import Modal (T-907) * fix: fix style of calendar (T-908) * fix: fix style of kanban (T-909) * fix: fix style of Gantt (T-910) * fix: fix style of Collapse (T-915) * fix: fix style of mobile (T-916) * fix: fix style of PageHeader (T-958) * fix: optimize background color of Drawer * fix: fix style of notification * fix: fix T-1000 * fix: fix style of LinkageHeader (T-1003) * fix: fix T-1004 * fix: fix style of scroll bar of chart (T-911) * fix: fix style of workflow drawer (T-997) * fix: fix T-922 * fix: fix T-924 * refactor: rename custom-theme to theme-editor * fix: fix T-999 * fix: fix T-1011 * fix: fix error * fix: optimize dark mode (T-921) * fix: fix style of markdown (T-1020) * fix: fix style of data template (T-1025) * fix: fix style of rich text (T-1026) * fix: fix style of a * fix: fix style of XButton (T-1028) * fix: fix T-1027 * fix: fix color of variable tag (T-1030) * chore: translation * feat: add a modal before create new theme (T-1024) * feat: highlight card when editing theme (T-1031) * feat: support to change theme name (T-1023) * fix: api.auth.getOption('theme') * fix: fix T-1032 * fix: fix feedback in feishu group * refactor: code review * fix: fix test * chore: rename * fix: useNotificationMiddleware * refactor: revert * fix: fix build * fix: notification * refactor: migrate CurrentUserProvider from Application to NocoBaseBuildInPlugin * fix: fix test * refactor: fix code review * chore: avoid test error --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-07-16 04:46:25 +00:00
theme,
)
.open({
initialValues: {
type: info.key,
},
})
.then(async (values) => {
try {
if (apiClient.resource('chartsQueries')?.create) {
const { data } = await apiClient.resource('chartsQueries').create({ values });
const items = (await ctx.refresh()) as any;
const item = items.find((item) => item.id === data?.data?.id);
onCreateBlockSchema({ item });
}
setVisible(false);
} catch (err) {
error(err);
}
})
.catch((err) => {
error(err);
});
},
[apiClient, ctx, onCreateBlockSchema, options.components, options.scope, setVisible],
);
const items = useMemo(() => {
const defaultItems: any = [
{
type: 'itemGroup',
title: lang('Select query data'),
children: [],
},
];
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
const chartQueryMetadata = ctx.data;
if (chartQueryMetadata && Array.isArray(chartQueryMetadata)) {
const item1 =
chartQueryMetadata.length > 0
? {
type: 'itemGroup',
title: '{{t("Select chart query", {ns: "charts"})}}',
children: chartQueryMetadata,
}
: null;
const item2 =
chartQueryMetadata.length > 0
? {
type: 'divider',
}
: null;
return [
item1,
item2,
{
type: 'subMenu',
title: lang('Add chart query'),
// component: AddChartQuery,
children: [
{
key: 'sql',
type: 'item',
title: 'SQL',
onClick: onAddQuery,
},
{
key: 'json',
type: 'item',
title: 'JSON',
onClick: onAddQuery,
},
],
},
].filter(Boolean);
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
}
return defaultItems;
}, [ctx.data, onAddQuery]);
feat: add chart plugin (#1477) * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * feat(demo): chart block initializer * fix: hello block * chore: init data analyse plugin * chore: add data-analyse plugin * chore: init plugin * chore: update * chore: export schema initializers * feat: add data analyse block * chore: update data analyse block initializer * chore: rename plugin name * chore: update * chore: update enum * chore: update add block * feat: add pie schema template * chore: refactor * chore: update * chore: init server * feat: add pie schema template * chore: add chart utils * chore: update * chore: update * chore: update * chore: update * feat: mvp * chore: update * chore: test * feat: example * fix: templates map error * chore: update * feat: add ChartBlockEngineDesigner.tsx * chore: clean code * chore: update templates * chore: init bat template * chore: update chart block engine * feat: add chart block engine designer * chore: update chart block initializer * chore: update pie template * chore: update * feat: split sql * chore: update * chore: clean * feat: support bar * chore: add bar template * chore: clean code * chore: clean code * fix: chart block initializer title * chore: update * fix: use title * chore: update * fix: bugs * chore: clean code * chore: update pie template * chore: update ChartBlockInitializer.tsx * chore: update * feat: support chart config * chore: add local plugin * feat: add column template * feat: add column chart action * feat: add line chart template * feat: add line action * feat: add area template * feat: add area action * chore: update pie template * chore: update * chore: update dep * fix: export missing utils * chore: update dep * chore: update dep * chore: update pie template * fix(charts): sql table capitalization * fix(charts): improve sql compatibility * fix: support choices type * chore: update * chore: clean code * chore: get collection fields in chart engine * chore: init dataset plugin * chore: init dataset designer * chore: init dataset block initializer * chore: update * chore: update * chore: update deps * chore: add tests * chore: update utils * chore: init plugin * feat: add datasets client * chore: update tests * chore: update datastructures * chore: update * feat: add DataSetBlockInitializer * chore: use dataset initializer * chore: update deps * chore: update * chore: update pie template * chore: update ChartBlockInitializer * chore: update ChartBlockEngine * chore: remove mdg file * chore: update ChartBlockEngine * chore: update * chore: update g2plot * chore: update template * chore: update pie handler * chore: update DataSetPreviewTable * chore: update ChartBlockEngine * chore: update ChartBlockEngineDesigner * chore: remove useless files * chore: update ChartBlockInitializer * chore: update template * chore: feat area template * chore: update tests * chore: update local plugins * chore: update deps * chore: update templates * chore: update template * feat: add CustomSelect * chore: update select component * fix: seriesField color error * chore: update template * chore: update * fix: bar * chore: update templates & clean code * chore: update templates * feat: add FunnelTemplate * feat: charts queries * fix: data shift * feat: add ChartQueryMetadataProvider * chore: update * chore: remove dataset * chore: update * chore: update * chore: clean code * fix: delete query query list wrong behavior * fix: delete all queries query list behavior * chore: add empty occupancy * chore: update description * chore: update chart icon * chore: update funnel template * chore: update template title * chore: add references * chore: update dialog height * fix: scatter template * chore: update popup description * refactor: schema level * refactor: charts schema * chore: remove console * chore: remove console * fix: error message * chore: remove console * chore: update DataSetPreviewTable * feat: chart icons * feat: update i18n * feat: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * feat: add tittle * chore: update icons * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * chore: update i18n * fix: improve code * chore: update i18n * chore: update i18n * fix: chart icon * feat: quick add query (#1527) * feat: quick add query * feat: query * chore: remove useless files * fix: json5 validator error * chore: update * chore: update style * chore: lint * feat: improve code * feat: sql validation * refactor: clean code * Update utils.ts * chore: format code * chore: remove useless file * chore: update --------- Co-authored-by: chenos <chenlinxh@gmail.com>
2023-03-04 11:36:58 +00:00
return (
<SchemaInitializer.Item
icon={<TableOutlined />}
{...others}
onClick={async ({ item }) => {
onCreateBlockSchema({ item });
setVisible(false);
}}
items={items}
/>
);
};