Skip to content

Commit 3829b09

Browse files
V15/sort by selected icons (#18158)
* adds back the custom icon for the content nodes and give a hover effect to indicate that it is grabable, and applys the choosen color * Update sort-children-of-modal.element.ts * switches to use the umb-icon and updates styling * removes the backoffice host * Update appsettings.Development.template.json * Update sort-children-of-modal.element.ts * Update sort-children-of-modal.element.ts --------- Co-authored-by: Mads Rasmussen <[email protected]>
1 parent 9323d8b commit 3829b09

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

src/Umbraco.Web.UI.Client/src/packages/core/tree/entity-actions/sort-children-of/modal/sort-children-of-modal.element.ts

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -287,8 +287,9 @@ export class UmbSortChildrenOfModalElement extends UmbModalBaseElement<
287287
}
288288

289289
#renderChild(item: UmbTreeItemModel) {
290-
return html` <uui-table-row data-unique=${item.unique} class="${this._isSorting ? 'hidden' : ''}">
291-
<uui-table-cell><uui-icon name="icon-navigation" aria-hidden="true"></uui-icon></uui-table-cell>
290+
// TODO: find a way to get the icon for the item. We do not have the icon in the tree item model.
291+
return html` <uui-table-row id="content-node" data-unique=${item.unique} class="${this._isSorting ? 'hidden' : ''}">
292+
<uui-table-cell><umb-icon name="icon-navigation"></umb-icon></uui-table-cell>
292293
<uui-table-cell>${item.name}</uui-table-cell>
293294
<uui-table-cell>${this.#renderCreateDate(item)}</uui-table-cell>
294295
</uui-table-row>`;
@@ -310,6 +311,14 @@ export class UmbSortChildrenOfModalElement extends UmbModalBaseElement<
310311
width: 100%;
311312
}
312313
314+
uui-table-cell {
315+
padding: var(--uui-size-space-2) var(--uui-size-space-5);
316+
}
317+
318+
uui-table-head-cell {
319+
padding: 0 var(--uui-size-space-5);
320+
}
321+
313322
uui-table-head-cell button {
314323
background-color: transparent;
315324
color: inherit;
@@ -328,9 +337,17 @@ export class UmbSortChildrenOfModalElement extends UmbModalBaseElement<
328337
visibility: hidden;
329338
}
330339
340+
uui-table-row[id='content-node']:hover {
341+
cursor: grab;
342+
}
343+
331344
uui-icon[name='icon-navigation'] {
332345
cursor: hand;
333346
}
347+
348+
uui-box {
349+
--uui-box-default-padding: 0;
350+
}
334351
`,
335352
];
336353
}

0 commit comments

Comments
 (0)