@@ -585,12 +585,23 @@ onBeforeUnmount(() => {
585585 backgroundColor: backgroundColor,
586586 border: `1px solid ${buttonBorderColor}`
587587 }" >
588- < BaseIcon name= " close" : stroke= " color" / >
588+ < slot name= " annotator-action-close" >
589+ < BaseIcon name= " close" : stroke= " color" / >
590+ < / slot>
589591 < / button>
592+
590593 < button class = " vue-ui-pen-and-paper-action" style= " padding: 0 !important" >
591- < ColorPicker v- model: value= " currentColor" : backgroundColor= " backgroundColor"
592- : buttonBorderColor= " buttonBorderColor" / >
594+ < ColorPicker
595+ v- model: value= " currentColor"
596+ : backgroundColor= " backgroundColor"
597+ : buttonBorderColor= " buttonBorderColor"
598+ >
599+ < template #annotator- action- color= " { color }" >
600+ < slot name= " annotator-action-color" v- bind= " { color }" / >
601+ < / template>
602+ < / ColorPicker>
593603 < / button>
604+
594605 < button
595606 data- cy= " pen-and-paper-toggle-text"
596607 class = " vue-ui-pen-and-paper-action"
@@ -600,8 +611,10 @@ onBeforeUnmount(() => {
600611 backgroundColor: backgroundColor,
601612 border: `1px solid ${buttonBorderColor}`,
602613 }"
603- >
604- < BaseIcon : name= " mode === 'draw' ? 'annotator' : 'text'" : stroke= " color" / >
614+ >
615+ < slot name= " annotator-action-draw" v- bind= " { mode }" >
616+ < BaseIcon : name= " mode === 'draw' ? 'annotator' : 'text'" : stroke= " color" / >
617+ < / slot>
605618 < div : style= " {
606619 position: 'absolute',
607620 bottom: '-20px',
@@ -626,21 +639,30 @@ onBeforeUnmount(() => {
626639 border: `1px solid ${buttonBorderColor}`,
627640 marginTop: '20px'
628641 }" >
629- < BaseIcon name= " restart" : stroke= " color" / >
642+ < slot name= " annotator-action-undo" v- bind= " { disabled: !stack.length }" >
643+ < BaseIcon name= " restart" : stroke= " color" / >
644+ < / slot>
630645 < / button>
646+
631647 < button class = " vue-ui-pen-and-paper-action"
632648 : class = " { 'vue-ui-pen-and-paper-action-disabled': !redoStack.length }" @click= " redoLastDraw" : style= " {
633649 backgroundColor: backgroundColor,
634650 border: `1px solid ${buttonBorderColor}`
635651 }" >
636- < BaseIcon name= " restart" : stroke= " color" style= " transform: scaleX(-1)" / >
652+ < slot name= " annotator-action-redo" v- bind= " { disabled: !redoStack.length}" >
653+ < BaseIcon name= " restart" : stroke= " color" style= " transform: scaleX(-1)" / >
654+ < / slot>
637655 < / button>
656+
638657 < button class = " vue-ui-pen-and-paper-action" : class = " { 'vue-ui-pen-and-paper-action-disabled': !stack.length }"
639658 @click= " reset" : style= " {
640659 backgroundColor: backgroundColor,
641660 border: `1px solid ${buttonBorderColor}`
642- }" >
643- < BaseIcon name= " trash" : stroke= " color" / >
661+ }"
662+ >
663+ < slot name= " annotator-action-delete" v- bind= " { disabled: !stack.length }" >
664+ < BaseIcon name= " trash" : stroke= " color" / >
665+ < / slot>
644666 < / button>
645667
646668 < input
0 commit comments