Web Component: j-Parts
j-Parts
This content can handle multiple parts stored in the Array and focus on one specific part. It simulates something like browser tabs.
- jComponent
v19|v20
Configuration:
parent{String}parent area due to part size (default:auto)margin{Number}vertical margin (default:0)create{String}a link to thefunction(part), it's executed if the part is created (called once)focus{String}a link to thefunction(part), it's executed if the part is focusedclose{String}a link to thefunction(part), it's executed if the part is closed
Good to know 1:
- all
~PATH~phrases will be replaced byitem.pathautomatically - all
~ID~phrases will be replaced byitem.idautomatically
Item specification:
item.id{String}very important, part identifieritem.blur{String/Function(el, item)}optional, a link to thefunction(element, item)if the part is focused outitem.focus{String/Function(el, item)}oritem.reload{String}optional, a link to thefunction(element, item)if the part is focuseditem.remove{String/Function(el, item)}optional, a link to thefunction(element, item)if the part is removeditem.html{String}a HTML content or useitem.urlitem.import{String}URL address for the part contentitem.path{String}optional, it replaces all~PATH~phrases automaticallyitem.delay{Number}a delay for removing ofinvisibleclass- NEW
item.attrd{Object}addsdata-keyattributes into the item element
Extendend by the component:
item.focused{Boolean}determines if the part is focused or notitem.element{jQuery}part element
Methods:
component.close(id)closes partcomponent.focus(id)focuses partcomponent.rename(id, name, [icon])renames part
Created
12. february 2022
Updated
20. february 2024
jComponent library
19 | 20
Version
v1
License
https://www.totaljs.com/license/
Responsive
Yes
Author
Peter Širka
Email
petersirka@gmail.com

