mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 15:35:28 +00:00
feat: change the schema component directory
This commit is contained in:
parent
f8181cbf74
commit
58683a7657
@ -7,19 +7,12 @@ export * from './admin-layout';
|
|||||||
export * from './antd-config-provider';
|
export * from './antd-config-provider';
|
||||||
export * from './api-client';
|
export * from './api-client';
|
||||||
export * from './auth-layout';
|
export * from './auth-layout';
|
||||||
export * from './checkbox';
|
|
||||||
export * from './collection-manager';
|
export * from './collection-manager';
|
||||||
export * from './current-user';
|
export * from './current-user';
|
||||||
export * from './document-title';
|
export * from './document-title';
|
||||||
export * from './route-switch';
|
export * from './route-switch';
|
||||||
export * from './schema-component';
|
export * from './schema-component';
|
||||||
export * from './system-settings';
|
export * from './system-settings';
|
||||||
export * from './action';
|
|
||||||
export * from './form';
|
|
||||||
export * from './form-item';
|
|
||||||
export * from './block-item';
|
|
||||||
export * from './dnd-context';
|
|
||||||
export * from './grid';
|
|
||||||
export * from './application';
|
export * from './application';
|
||||||
export * from './record-provider';
|
export * from './record-provider';
|
||||||
export * from './async-data-provider';
|
export * from './async-data-provider';
|
||||||
|
@ -5,4 +5,4 @@ group:
|
|||||||
path: /schema-components
|
path: /schema-components
|
||||||
---
|
---
|
||||||
|
|
||||||
# SubTable <Badge>待定</Badge>
|
# ArrayTable <Badge>待定</Badge>
|
@ -1,5 +1,5 @@
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { useDesignable } from '../schema-component';
|
import { useDesignable } from '../..';
|
||||||
|
|
||||||
export const BlockItem: React.FC<any> = (props) => {
|
export const BlockItem: React.FC<any> = (props) => {
|
||||||
const { DesignableBar } = useDesignable();
|
const { DesignableBar } = useDesignable();
|
@ -10,8 +10,7 @@ const schema = {
|
|||||||
type: 'object',
|
type: 'object',
|
||||||
properties: {
|
properties: {
|
||||||
input: {
|
input: {
|
||||||
interface: 'string',
|
type: 'boolean',
|
||||||
type: 'string',
|
|
||||||
title: `编辑模式`,
|
title: `编辑模式`,
|
||||||
'x-decorator': 'FormItem',
|
'x-decorator': 'FormItem',
|
||||||
'x-component': 'Checkbox',
|
'x-component': 'Checkbox',
|
||||||
@ -25,8 +24,7 @@ const schema = {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
read: {
|
read: {
|
||||||
interface: 'string',
|
type: 'boolean',
|
||||||
type: 'string',
|
|
||||||
title: `阅读模式`,
|
title: `阅读模式`,
|
||||||
'x-read-pretty': true,
|
'x-read-pretty': true,
|
||||||
'x-decorator': 'FormItem',
|
'x-decorator': 'FormItem',
|
@ -23,7 +23,7 @@ const schema = {
|
|||||||
type: 'object',
|
type: 'object',
|
||||||
properties: {
|
properties: {
|
||||||
input: {
|
input: {
|
||||||
type: 'string',
|
type: 'array',
|
||||||
title: `编辑模式`,
|
title: `编辑模式`,
|
||||||
enum: options,
|
enum: options,
|
||||||
'x-decorator': 'FormItem',
|
'x-decorator': 'FormItem',
|
||||||
@ -38,7 +38,7 @@ const schema = {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
read: {
|
read: {
|
||||||
type: 'string',
|
type: 'array',
|
||||||
title: `阅读模式`,
|
title: `阅读模式`,
|
||||||
enum: options,
|
enum: options,
|
||||||
'x-read-pretty': true,
|
'x-read-pretty': true,
|
@ -1,7 +1,7 @@
|
|||||||
import { DndContext as DndKitContext, DragEndEvent } from '@dnd-kit/core';
|
import { DndContext as DndKitContext, DragEndEvent } from '@dnd-kit/core';
|
||||||
import { observer } from '@formily/react';
|
import { observer } from '@formily/react';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { createDesignable, useDesignable } from '../schema-component';
|
import { createDesignable, useDesignable } from '../..';
|
||||||
|
|
||||||
const useDragEnd = () => {
|
const useDragEnd = () => {
|
||||||
const { refresh } = useDesignable();
|
const { refresh } = useDesignable();
|
@ -11,7 +11,7 @@ import {
|
|||||||
useField,
|
useField,
|
||||||
useFieldSchema,
|
useFieldSchema,
|
||||||
} from '@formily/react';
|
} from '@formily/react';
|
||||||
import { SchemaComponent, useAttach } from '../schema-component';
|
import { SchemaComponent, useAttach } from '../..';
|
||||||
|
|
||||||
type ComposedForm = React.FC<any> & {
|
type ComposedForm = React.FC<any> & {
|
||||||
__NOCOBASE_FORM?: boolean;
|
__NOCOBASE_FORM?: boolean;
|
7
packages/client/src/schema-component/antd/index.tsx
Normal file
7
packages/client/src/schema-component/antd/index.tsx
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
export * from './checkbox';
|
||||||
|
export * from './action';
|
||||||
|
export * from './form';
|
||||||
|
export * from './form-item';
|
||||||
|
export * from './block-item';
|
||||||
|
export * from './dnd-context';
|
||||||
|
export * from './grid';
|
@ -0,0 +1,16 @@
|
|||||||
|
---
|
||||||
|
nav:
|
||||||
|
path: /client
|
||||||
|
group:
|
||||||
|
path: /schema-components
|
||||||
|
---
|
||||||
|
|
||||||
|
# VoidTable <Badge>待定</Badge>
|
||||||
|
|
||||||
|
- VoidTable
|
||||||
|
- VoidTable.Column
|
||||||
|
- VoidTable.SortHandle
|
||||||
|
- TaVoidTableble.Index
|
||||||
|
- VoidTable.Pagination
|
||||||
|
- VoidTable.ActionBar
|
||||||
|
- VoidTable.Filter
|
@ -2,3 +2,4 @@ export * from './components';
|
|||||||
export * from './context';
|
export * from './context';
|
||||||
export * from './hooks';
|
export * from './hooks';
|
||||||
export * from './types';
|
export * from './types';
|
||||||
|
export * from './antd';
|
||||||
|
@ -1,16 +0,0 @@
|
|||||||
---
|
|
||||||
nav:
|
|
||||||
path: /client
|
|
||||||
group:
|
|
||||||
path: /schema-components
|
|
||||||
---
|
|
||||||
|
|
||||||
# Table <Badge>待定</Badge>
|
|
||||||
|
|
||||||
- Table
|
|
||||||
- Table.Column
|
|
||||||
- Table.SortHandle
|
|
||||||
- Table.Index
|
|
||||||
- Table.Pagination
|
|
||||||
- Table.ActionBar
|
|
||||||
- Table.Filter
|
|
Loading…
Reference in New Issue
Block a user