We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8adf130 commit 7ac0c02Copy full SHA for 7ac0c02
1 file changed
resources/assets/js/app.js
@@ -647,8 +647,11 @@ $(function() {
647
// Trix editor settings
648
if (typeof Trix === 'object') {
649
document.addEventListener('trix-initialize', (e) => {
650
- document.querySelector('trix-toolbar .trix-button-group--history-tools').remove();
651
- document.querySelector('trix-toolbar .trix-button-group--file-tools').remove();
+ const history_tools = document.querySelector('trix-toolbar .trix-button-group--history-tools');
+ const file_tools = document.querySelector('trix-toolbar .trix-button-group--file-tools');
652
+
653
+ if (history_tools) history_tools.remove();
654
+ if (file_tools) file_tools.remove();
655
});
656
document.addEventListener('trix-file-accept', (e) => {
657
e.preventDefault();
0 commit comments