Toggle button

I want to use the toggle button (highlighted below) in my user interface - similar to that used in the Profile Settings --> Email notifications interface.

Is this available anywhere or on the Appmarket?

Thanks!

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer

    a!localVariables(
      local!value: true,
      a!richTextDisplayField(
        value: {
          a!richTextItem(
            size: "MEDIUM_PLUS",
            text: {
              a!richTextIcon(
                icon: "toggle-on",
                showWhen: local!value = true,
                link: a!dynamicLink(
                  saveInto: {
                    a!save(local!value, false)
                  }
                ),
                linkStyle: "STANDALONE"
              ),
              a!richTextIcon(
                icon: "toggle-off",
                showWhen: local!value =false,
                link: a!dynamicLink(
                  saveInto: {
                    a!save(local!value,true)
                  }
                ),
                linkStyle: "STANDALONE"
              )
            }
          )
        }
      )
    )

    Hi, you can use Rich Text Display Field containing a Rich Text Icon using the "toggle-on" / "toggle-off" icons. And on links use dynamic link to update the variable value.

Reply
  • 0
    Certified Lead Developer

    a!localVariables(
      local!value: true,
      a!richTextDisplayField(
        value: {
          a!richTextItem(
            size: "MEDIUM_PLUS",
            text: {
              a!richTextIcon(
                icon: "toggle-on",
                showWhen: local!value = true,
                link: a!dynamicLink(
                  saveInto: {
                    a!save(local!value, false)
                  }
                ),
                linkStyle: "STANDALONE"
              ),
              a!richTextIcon(
                icon: "toggle-off",
                showWhen: local!value =false,
                link: a!dynamicLink(
                  saveInto: {
                    a!save(local!value,true)
                  }
                ),
                linkStyle: "STANDALONE"
              )
            }
          )
        }
      )
    )

    Hi, you can use Rich Text Display Field containing a Rich Text Icon using the "toggle-on" / "toggle-off" icons. And on links use dynamic link to update the variable value.

Children