Add templates for object action delete and toggle icons
authorMatthias Schmidt <gravatronics@live.com>
Wed, 17 Mar 2021 15:07:16 +0000 (16:07 +0100)
committerMatthias Schmidt <gravatronics@live.com>
Sun, 21 Mar 2021 09:21:39 +0000 (10:21 +0100)
com.woltlab.wcf/templates/__objectActionDeleteIcon.tpl [new file with mode: 0644]
com.woltlab.wcf/templates/__objectActionToogleIcon.tpl [new file with mode: 0644]
syncTemplates.json
wcfsetup/install/files/acp/templates/__objectActionDeleteIcon.tpl [new file with mode: 0644]
wcfsetup/install/files/acp/templates/__objectActionToogleIcon.tpl [new file with mode: 0644]

diff --git a/com.woltlab.wcf/templates/__objectActionDeleteIcon.tpl b/com.woltlab.wcf/templates/__objectActionDeleteIcon.tpl
new file mode 100644 (file)
index 0000000..3e98179
--- /dev/null
@@ -0,0 +1,5 @@
+<span class="icon icon16 fa-times jsObjectAction jsTooltip pointer" {*
+    *}title="{lang}wcf.global.button.delete{/lang}"  {*
+    *}data-object-action="delete" {*
+    *}{if $objectActionConfirmMessage}data-confirm-message="{lang __encode=true}{$objectActionConfirmMessage}{/lang}" {/if}{*
+*}></span>
diff --git a/com.woltlab.wcf/templates/__objectActionToogleIcon.tpl b/com.woltlab.wcf/templates/__objectActionToogleIcon.tpl
new file mode 100644 (file)
index 0000000..b4c22f9
--- /dev/null
@@ -0,0 +1,4 @@
+<span class="icon icon16 fa-{if !$object->isDisabled}check-{/if}square-o jsObjectAction jsTooltip pointer" {*
+    *}title="{lang}wcf.global.button.{if !$object->isDisabled}disable{else}enable{/if}{/lang}" {*
+    *}data-object-action="toggle"{*
+*}></span>
index 4de5d1deec21eda36bc619c09cd58b4d8c779eee..df54e5617c933bc6cf35dfbf613bcebdba82be5c 100644 (file)
@@ -33,6 +33,8 @@
     "__multipleSelectionFormField",
     "__nonEmptyFormFieldDependency",
     "__numericFormField",
+    "__objectActionDeleteIcon",
+    "__objectActionToogleIcon",
     "__pollOptionsFormField",
     "__radioButtonFormField",
     "__ratingFormField",
diff --git a/wcfsetup/install/files/acp/templates/__objectActionDeleteIcon.tpl b/wcfsetup/install/files/acp/templates/__objectActionDeleteIcon.tpl
new file mode 100644 (file)
index 0000000..3e98179
--- /dev/null
@@ -0,0 +1,5 @@
+<span class="icon icon16 fa-times jsObjectAction jsTooltip pointer" {*
+    *}title="{lang}wcf.global.button.delete{/lang}"  {*
+    *}data-object-action="delete" {*
+    *}{if $objectActionConfirmMessage}data-confirm-message="{lang __encode=true}{$objectActionConfirmMessage}{/lang}" {/if}{*
+*}></span>
diff --git a/wcfsetup/install/files/acp/templates/__objectActionToogleIcon.tpl b/wcfsetup/install/files/acp/templates/__objectActionToogleIcon.tpl
new file mode 100644 (file)
index 0000000..b4c22f9
--- /dev/null
@@ -0,0 +1,4 @@
+<span class="icon icon16 fa-{if !$object->isDisabled}check-{/if}square-o jsObjectAction jsTooltip pointer" {*
+    *}title="{lang}wcf.global.button.{if !$object->isDisabled}disable{else}enable{/if}{/lang}" {*
+    *}data-object-action="toggle"{*
+*}></span>