File tree Expand file tree Collapse file tree 4 files changed +16
-11
lines changed Expand file tree Collapse file tree 4 files changed +16
-11
lines changed Original file line number Diff line number Diff line change @@ -2,4 +2,6 @@ import ReactDOM from 'react-dom';
2
2
import CreateDiagramDialog from './components/create-diagram-dialog' ;
3
3
import './styles.css' ;
4
4
5
- ReactDOM . render ( < CreateDiagramDialog /> , document . getElementById ( 'index' ) ) ;
5
+ const container = document . getElementById ( 'index' ) ;
6
+ const root = ReactDOM . createRoot ( container ) ;
7
+ root . render ( < CreateDiagramDialog /> ) ;
Original file line number Diff line number Diff line change @@ -3,4 +3,6 @@ import EditDiagramDialog from './components/edit-diagram-dialog';
3
3
4
4
import './styles.css' ;
5
5
6
- ReactDOM . render ( < EditDiagramDialog /> , document . getElementById ( 'index' ) ) ;
6
+ const container = document . getElementById ( 'index' ) ;
7
+ const root = ReactDOM . createRoot ( container ) ;
8
+ root . render ( < EditDiagramDialog /> ) ;
Original file line number Diff line number Diff line change @@ -2,4 +2,6 @@ import ReactDOM from 'react-dom';
2
2
import SelectDiagramDialog from './components/select-diagram-dialog' ;
3
3
import './styles.css' ;
4
4
5
- ReactDOM . render ( < SelectDiagramDialog /> , document . getElementById ( 'index' ) ) ;
5
+ const container = document . getElementById ( 'index' ) ;
6
+ const root = ReactDOM . createRoot ( container ) ;
7
+ root . render ( < SelectDiagramDialog /> ) ;
Original file line number Diff line number Diff line change @@ -12,13 +12,13 @@ export const onOpen = () => {
12
12
} ;
13
13
14
14
export const openCreateDiagramDialog = ( ) => {
15
- const code = checkChartsLimit ( ) ;
16
- if ( code === 401 ) {
17
- DocumentApp . getUi ( ) . alert (
18
- 'You have reached your five diagram limit on the Free tier.'
19
- ) ;
20
- return ;
21
- }
15
+ // const code = checkChartsLimit();
16
+ // if (code === 401) {
17
+ // DocumentApp.getUi().alert(
18
+ // 'You have reached your five diagram limit on the Free tier.'
19
+ // );
20
+ // return;
21
+ // }
22
22
const html = HtmlService . createHtmlOutputFromFile ( 'create-diagram-dialog' )
23
23
. append (
24
24
`<script>
@@ -58,7 +58,6 @@ export const openEditDiagramDialog = () => {
58
58
} ;
59
59
60
60
export const openSelectDiagramDialog = ( ) => {
61
- const doc = DocumentApp . getActiveDocument ( ) ;
62
61
const html = HtmlService . createHtmlOutputFromFile ( 'select-diagram-dialog' )
63
62
. append (
64
63
`<script>
You can’t perform that action at this time.
0 commit comments