Skip to content

Commit 18083ad

Browse files
authored
[6.x] Revert floating toolbar buttons which were inadvertently affected by #14036 (#14118)
Revert floating toolbar buttons which were accidentally affected by the Floating toolbar keyboard shortcuts PR
1 parent fcb8ada commit 18083ad

1 file changed

Lines changed: 2 additions & 12 deletions

File tree

resources/js/components/fieldtypes/bard/ToolbarButton.vue

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,11 @@
44
:class="{ active, group: variant === 'floating' }"
55
:variant="variant === 'floating' ? 'subtle' : 'ghost'"
66
size="sm"
7-
:aria-label="tooltipText"
8-
v-tooltip="tooltipText"
7+
:aria-label="button.text"
8+
v-tooltip="button.text"
99
@click="button.command(editor, button.args)"
1010
>
1111
<ui-icon :name="button.svg" v-if="button.svg" class="size-3.5! " :class="{ 'group-hover:text-white text-yellow-300!': active && variant === 'floating' }" />
12-
<span v-if="variant === 'floating' && (button.text || button.shortcutKey)" class="ml-1 text-xs">{{ button.text }}{{ button.shortcutKey ? ` ${button.shortcutKey}` : '' }}</span>
1312
<div class="flex items-center" v-html="button.html" v-if="button.html" />
1413
</Button>
1514
</template>
@@ -29,14 +28,5 @@ export default {
2928
bard: {},
3029
editor: {},
3130
},
32-
computed: {
33-
tooltipText() {
34-
const label = this.button?.text ?? '';
35-
if (this.button?.shortcutKey) {
36-
return label ? `${label} (${this.button.shortcutKey})` : this.button.shortcutKey;
37-
}
38-
return label;
39-
},
40-
},
4131
};
4232
</script>

0 commit comments

Comments
 (0)