Edit online

Floating Toolbar: -oxy-floating-toolbar Property

Used to display a configured floating toolbar in Author mode.

The -oxy-floating-toolbar property is used to configure and display a floating toolbar in Author mode. It accepts a space-separated list of the following functions:
  • oxy_button
  • oxy_buttonGroup
  • oxy_checkbox
  • oxy_combobox
  • oxy_label
Note: The "|" text value can be used to add a separator between elements of the toolbar.

It must be used in conjunction with the -oxy-selected and -oxy-selection-inside pseudo-classes. The -oxy-selected pseudo-class is automatically set on an element that is fully selected and the -oxy-selection-inside pseudo-class is automatically set on an element that has a selection inside.

Example 1:
p:-oxy-selection-inside {
    -oxy-floating-toolbar: 
        oxy_button(actionID, 'bold')
        oxy_button(actionID, 'italic')
        oxy_button(actionID, 'underline')
}

This results in a floating toolbar that contains bold, italic, and underline actions presented in Author mode every time text inside a paragraph element is selected.

Example 2:
p:-oxy-selected {
    -oxy-floating-toolbar: 
        oxy_label(text, "Platform: ")
        oxy_combobox(
            edit, '@platform', 
            editable, false, 
            values, 'windows, mac, linux', 
            labels, 'Windows, MacOS, Linux'
            )
}

This results in a floating toolbar that contains a Platform: label and a drop-down menu used to change the value of the @platform profiling attribute. This is presented in Author mode every time a paragraph element is fully selected.

Example 3:
[conref]:-oxy-selected, [conkeyref]:-oxy-selected {
    -oxy-floating-toolbar: 
        oxy_button(actionID, 'add_edit_content_reference')
        oxy_button(actionID, 'remove_content_reference')
        "|"
        oxy_button(actionID, 'conref.replace')
}

This results in a floating toolbar that contains the Insert table row above, Insert table row below, and Delete table row actions presented in Author mode every time an element with a @conref or @conkeyref attribute is fully selected.