File tree Expand file tree Collapse file tree 5 files changed +4
-29
lines changed
views/themes/admin/content/widget
ui-dev/src/modules/universal-discovery/components/content-create-widget Expand file tree Collapse file tree 5 files changed +4
-29
lines changed Original file line number Diff line number Diff line change 88 createActions . forEach ( ( container ) => {
99 const radioInputs = container . querySelectorAll ( '.form-check [type="radio"]' ) ;
1010 const submitBtn = container . querySelector ( '.ibexa-extra-actions__btn--confirm' ) ;
11- const cancelBtn = container . querySelector ( '.ibexa-extra-actions__btn--cancel' ) ;
12- const closeBtn = container . querySelector ( '.ibexa-extra-actions__header .ibexa-btn--close' ) ;
1311
14- cancelBtn . addEventListener (
15- 'click' ,
16- ( ) => {
17- closeBtn . click ( ) ;
18- } ,
19- false ,
20- ) ;
2112 radioInputs . forEach ( ( radioInput ) =>
2213 radioInput . addEventListener (
2314 'change' ,
Original file line number Diff line number Diff line change 22 const CLASS_HIDDEN = 'ibexa-extra-actions--hidden' ;
33 const CLASS_EXPANDED = 'ibexa-context-menu--expanded' ;
44 const CLASS_PREVENT_SHOW = 'ibexa-extra-actions--prevent-show' ;
5+ const closeBtns = doc . querySelectorAll (
6+ '.ibexa-extra-actions .ibexa-btn--close, .ibexa-extra-actions .ibexa-extra-actions__btn--cancel' ,
7+ ) ;
58 const btns = [ ...doc . querySelectorAll ( '.ibexa-btn--extra-actions' ) ] ;
69 const menu = doc . querySelector ( '.ibexa-context-menu' ) ;
710 const backdrop = new ibexa . core . Backdrop ( ) ;
7881 initExtraActionsWidget ( dataset ) ;
7982 } ) ;
8083 doc . body . addEventListener ( 'ibexa-extra-actions:toggle-widget' , ( event ) => toggleExtraActionsWidget ( event . detail ) , false ) ;
81- doc . querySelectorAll ( '.ibexa-extra-actions .ibexa-btn--close' ) . forEach ( ( closeBtn ) =>
84+ closeBtns . forEach ( ( closeBtn ) =>
8285 closeBtn . addEventListener (
8386 'click' ,
8487 ( event ) => {
Original file line number Diff line number Diff line change 1010 <div class =" ibexa-extra-actions ibexa-extra-actions--create ibexa-extra-actions--hidden" data-actions =" {{ data_actions }}" >
1111 <div class =" ibexa-extra-actions__header" >
1212 <h2 >{{ ' content.create.create_content' | trans| desc(' Create content' ) }}</h2 >
13- <button
14- type =" button"
15- class =" btn ibexa-btn ibexa-btn--ghost ibexa-btn--small ibexa-btn--no-text ibexa-btn--close"
16- >
17- <svg class =" ibexa-icon ibexa-icon--small" >
18- <use xlink:href =" {{ ibexa_icon_path(' discard' ) }}" ></use >
19- </svg >
20- </button >
2113 <div class =" ibexa-extra-actions__header-subtitle" >
2214 {% if content is defined %}
2315 {{ ' content.create.editing_details' | trans({ ' %content%' : ibexa_content_name(content ) })| desc(' under %content%' ) }}
Original file line number Diff line number Diff line change @@ -82,7 +82,6 @@ const ContentCreateWidget = () => {
8282 'ibexa_universal_discovery_widget' ,
8383 ) ;
8484 const createLabel = Translator . trans ( /*@Desc ("Create")*/ 'create_content.create' , { } , 'ibexa_universal_discovery_widget' ) ;
85- const closeLabel = Translator . trans ( /*@Desc ("Close")*/ 'popup.close.label' , { } , 'ibexa_universal_discovery_widget' ) ;
8685 const cancelLabel = Translator . trans ( /*@Desc ("Discard")*/ 'content_create.cancel.label' , { } , 'ibexa_universal_discovery_widget' ) ;
8786 const placeholder = Translator . trans (
8887 /*@Desc ("Search by content type")*/ 'content_create.placeholder' ,
@@ -132,15 +131,6 @@ const ContentCreateWidget = () => {
132131 < div className = { widgetClassName } ref = { refContentTree } >
133132 < div className = "ibexa-extra-actions__header" >
134133 < h3 > { createContentLabel } </ h3 >
135- < button
136- type = "button"
137- className = "btn ibexa-btn ibexa-btn--ghost ibexa-btn--no-text ibexa-btn--close"
138- onClick = { close }
139- title = { closeLabel }
140- data-tooltip-container-selector = ".c-udw-tab"
141- >
142- < Icon name = "discard" extraClasses = "ibexa-icon--small" />
143- </ button >
144134 < div className = "ibexa-extra-actions__header-subtitle" > { createUnderLabel } </ div >
145135 </ div >
146136 < div className = "ibexa-extra-actions__content ibexa-extra-actions__content--create" >
Original file line number Diff line number Diff line change @@ -161,7 +161,6 @@ public function createStructure(array $options): ItemInterface
161161 $ createAttributes = [
162162 'class ' => 'ibexa-btn--extra-actions ibexa-btn--create ibexa-btn--primary ' ,
163163 'data-actions ' => 'create ' ,
164- 'data-focus-element ' => '.ibexa-instant-filter__input ' ,
165164 ];
166165 $ sendToTrashAttributes = [
167166 'data-bs-toggle ' => 'modal ' ,
You can’t perform that action at this time.
0 commit comments