You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<span>{__('These blocks can be enabled in the Stackable settings page. Do you want to keep the disabled blocks or substitute them with other Stackable or core blocks?',i18n)}</span>
369
-
</div>
370
-
<Flexdirection="column"align="flex-end">
371
-
<Button
372
-
__next40pxDefaultSize
373
-
variant="primary"
374
-
onClick={()=>onClickPrimary()}
375
-
>
376
-
{__('Add patterns and substitute blocks',i18n)}
377
-
</Button>
378
-
<Button
379
-
__next40pxDefaultSize
380
-
variant="secondary"
381
-
onClick={()=>onClickSecondary()}
382
-
>
383
-
{__('Add patterns only (no substitutes)',i18n)}
384
-
</Button>
385
-
<Button
386
-
__next40pxDefaultSize
387
-
variant="tertiary"
388
-
onClick={()=>onClickTertiary()}
389
-
>
390
-
{__('Enable blocks in settings',i18n)}
391
-
</Button>
392
-
</Flex>
391
+
{isDialogOpen===DIALOG_OPTIONS.REMOVE_BLOCKS&&<>
392
+
<div>
393
+
<span>
394
+
{__('Adding this page design will replace all existing blocks in the editor. Are you sure you want to continue?',i18n)}
395
+
</span>
396
+
</div>
397
+
<Flexjustify="flex-end">
398
+
<Button
399
+
__next40pxDefaultSize
400
+
variant="secondary"
401
+
onClick={()=>{
402
+
blocksToRemoveRef.current=[]
403
+
setIsDialogOpen(DIALOG_OPTIONS.CLOSE)
404
+
}}
405
+
>
406
+
{__('Cancel',i18n)}
407
+
</Button>
408
+
<Button
409
+
__next40pxDefaultSize
410
+
variant="primary"
411
+
onClick={()=>{
412
+
if(disabledBlocksRef.current.size){
413
+
// Close this dialog and reopen after a while to show the notice for disabled blocks
<span>{__('These blocks can be enabled in the Stackable settings page. Do you want to keep the disabled blocks or substitute them with other Stackable or core blocks?',i18n)}</span>
0 commit comments