@@ -6,7 +6,7 @@ import * as LongText from "front-end/lib/components/form-field/long-text";
6
6
import * as NumberField from "front-end/lib/components/form-field/number" ;
7
7
import * as RadioGroup from "front-end/lib/components/form-field/radio-group" ;
8
8
import * as PlateEditor from "front-end/lib/components/form-field/plate-editor" ;
9
- import * as AIEditor from "front-end/lib/components/platejs/ui/ai-chat-editor" ;
9
+
10
10
import * as Select from "front-end/lib/components/form-field/select" ;
11
11
import * as ShortText from "front-end/lib/components/form-field/short-text" ;
12
12
import * as TabbedForm from "front-end/lib/components/tabbed-form" ;
@@ -49,29 +49,8 @@ import {
49
49
} from "shared/lib/validation" ;
50
50
import * as opportunityValidation from "shared/lib/validation/opportunity/team-with-us" ;
51
51
import * as genericValidation from "shared/lib/validation/opportunity/utility" ;
52
+
52
53
import Icon from "front-end/lib/views/icon" ;
53
- import { Plate , usePlateEditor } from "platejs/react" ;
54
- import { AIKit } from "front-end/lib/components/platejs/components/editor/plugins/ai-kit" ;
55
- import {
56
- Editor ,
57
- EditorContainer
58
- } from "front-end/lib/components/platejs/ui/editor" ;
59
- import { FixedToolbarKit } from "front-end/lib/components/platejs/components/editor/plugins/fixed-toolbar-kit" ;
60
- import { MarkdownKit } from "front-end/lib/components/platejs/components/editor/plugins/markdown-kit" ;
61
- import { BaseBasicBlocksKit } from "front-end/lib/components/platejs/components/editor/plugins/basic-blocks-base-kit" ;
62
- import { BasicMarksKit } from "front-end/lib/components/platejs/components/editor/plugins/basic-marks-kit" ;
63
- import { CommentKit } from "front-end/lib/components/platejs/components/editor/plugins/comment-kit" ;
64
- import { ListKit } from "front-end/lib/components/platejs/components/editor/plugins/list-kit" ;
65
- import { BasicBlocksKit } from "front-end/lib/components/platejs/components/editor/plugins/basic-blocks-kit" ;
66
- import { MediaKit } from "front-end/lib/components/platejs/components/editor/plugins/media-kit" ;
67
- import { AutoformatKit } from "front-end/lib/components/platejs/components/editor/plugins/autoformat-kit" ;
68
- import { CursorOverlayKit } from "front-end/lib/components/platejs/components/editor/plugins/cursor-overlay-kit" ;
69
- import { DndKit } from "front-end/lib/components/platejs/components/editor/plugins/dnd-kit" ;
70
- import { ExitBreakKit } from "front-end/lib/components/platejs/components/editor/plugins/exit-break-kit" ;
71
- import { TrailingBlockPlugin } from "platejs" ;
72
- import { BlockPlaceholderKit } from "front-end/lib/components/platejs/components/editor/plugins/block-placeholder-kit" ;
73
- import { BlockMenuKit } from "front-end/lib/components/platejs/components/editor/plugins/block-menu-kit" ;
74
- import { EditorKit } from "front-end/lib/components/platejs/components/editor/editor-kit" ;
75
54
76
55
type RemoteOk = "yes" | "no" ;
77
56
@@ -591,7 +570,7 @@ export function validate(state: Immutable<State>): Immutable<State> {
591
570
. update ( "completionDate" , ( s ) => FormField . validate ( s ) )
592
571
. update ( "maxBudget" , ( s ) => FormField . validate ( s ) )
593
572
. update ( "resources" , ( s ) => Resources . validate ( s ) )
594
- . update ( "description" , ( s ) => PlateEditor . validateState ( s ) )
573
+ . update ( "description" , ( s ) => PlateEditor . validate ( s ) )
595
574
. update ( "resourceQuestions" , ( s ) => ResourceQuestions . validate ( s ) )
596
575
. update ( "questionsWeight" , ( s ) => FormField . validate ( s ) )
597
576
. update ( "challengeWeight" , ( s ) => FormField . validate ( s ) )
@@ -1522,68 +1501,9 @@ export const DescriptionView: component_.base.View<Props> = ({
1522
1501
const startDate = DateField . getValueAsString ( state . startDate ) ;
1523
1502
const completionDate = DateField . getValueAsString ( state . completionDate ) ;
1524
1503
1525
- // const editor = usePlateEditor({
1526
- // plugins: [
1527
- // ...AIKit,
1528
- // ...BlockMenuKit,
1529
-
1530
- // // Elements
1531
- // ...BasicBlocksKit,
1532
- // // ...CodeBlockKit,
1533
- // // ...TableKit,
1534
- // // ...ToggleKit,
1535
- // // ...TocKit,
1536
- // ...MediaKit,
1537
- // // ...CalloutKit,
1538
- // // ...ColumnKit,
1539
- // // ...MathKit,
1540
- // // ...DateKit,
1541
- // // ...LinkKit,
1542
- // // ...MentionKit,
1543
-
1544
- // // Marks
1545
- // ...BasicMarksKit,
1546
- // // ...FontKit,
1547
- // // Block Style
1548
- // ...ListKit,
1549
- // // ...AlignKit,
1550
- // // ...LineHeightKit,
1551
-
1552
- // // Collaboration
1553
- // // ...DiscussionKit,
1554
- // ...CommentKit,
1555
- // // ...SuggestionKit,
1556
- // // Editing
1557
- // // ...SlashKit,
1558
- // ...AutoformatKit,
1559
- // ...CursorOverlayKit,
1560
- // ...DndKit,
1561
- // // ...EmojiKit,
1562
- // ...ExitBreakKit,
1563
- // TrailingBlockPlugin,
1564
- // // Parsers
1565
- // // ...DocxKit,
1566
- // ...MarkdownKit,
1567
- // // UI
1568
- // ...BlockPlaceholderKit,
1569
- // ...FixedToolbarKit,
1570
- // // ...FloatingToolbarKit,
1571
- // ],
1572
- // });
1573
-
1574
- const editor = usePlateEditor ( {
1575
- plugins : EditorKit ,
1576
- } ) ;
1577
-
1578
1504
return (
1579
1505
< Row >
1580
1506
< Col xs = "12" >
1581
- { /* <Plate editor={editor}>
1582
- <EditorContainer variant="demo">
1583
- <Editor />
1584
- </EditorContainer>
1585
- </Plate> */ }
1586
-
1587
1507
< PlateEditor . view
1588
1508
required
1589
1509
label = "Description and Contract Details"
0 commit comments