{"id":18882430,"url":"https://github.com/7studio/tabembed","last_synced_at":"2025-10-05T20:37:58.180Z","repository":{"id":15535927,"uuid":"18270621","full_name":"7studio/tabembed","owner":"7studio","description":"A component for tabbed interfaces","archived":false,"fork":false,"pushed_at":"2014-05-12T21:45:33.000Z","size":184,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-31T03:42:55.900Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://7studio.github.io/tabembed/test.html","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/7studio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-03-30T18:36:13.000Z","updated_at":"2014-05-12T21:45:33.000Z","dependencies_parsed_at":"2022-08-26T19:01:11.783Z","dependency_job_id":null,"html_url":"https://github.com/7studio/tabembed","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/7studio%2Ftabembed","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/7studio%2Ftabembed/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/7studio%2Ftabembed/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/7studio%2Ftabembed/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/7studio","download_url":"https://codeload.github.com/7studio/tabembed/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239850432,"owners_count":19707349,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-08T06:58:20.654Z","updated_at":"2025-10-05T20:37:53.154Z","avatar_url":"https://github.com/7studio.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TabEmbed\n\nThis is TabEmbed, a minimalist, opinionated component to lay-out your contents within a tabbed interface.\nIt gives you a small, adaptive HTML/CSS base on which you can apply your design decisions.\nThe objective is to keep the component independent of its context and content but also to undo or overide as less as possible.\nNaturally, it is handled by JavaScript (with a handy API) which takes all the advantages of CSS. JavaScript is only for sugar!\n\n## JavaScript Options\n\nAll options are optional and set up with usable defaults. Change them according to your needs.\n\n### `animation`\n\n`Boolean` or `PlainObject` indicates if the component should use CSS animations when the elements are changing.\n\nDefault value is false.\n\n### `hashchange`\n\n`Boolean` indicates if the component takes into account the window's hash changes and should use the History object when the elements are changing.\n\nDefault value is false.\n\n## JavaScript API\n\n### `new TabEmbed(element[, options])`\n\nReturns a new `TabEmbed` instance configured with the options described above.\n\n```js\nvar t = new TabEmbed(\"#Product-TabEmbed\");\n\n// plays and uses any of the other documented API methods\n```\n\n### `length`\n\nThe number of elements in this component. **Read only**.\n\n```js\nvar t = new TabEmbed(\"#Product-TabEmbed\");\n\nt.length;\n// -\u003e 3\n```\n\n### `elements`\n\nThe set of elements contained by this component. **Read only**.\n\n```js\nvar t = new TabEmbed(\"#Product-TabEmbed\");\n\nt.elements;\n// -\u003e [\n// -\u003e   { index: 0, defaultSelected: true, disabled: false, selected: true, name: \"Technical-Details\", tab: [object HTMLLIElement], tabpanel: [object HTMLDivElement] },\n// -\u003e   { index: 1, defaultSelected: false, disabled: true, selected: false, name: \"Features\", tab: [object HTMLLIElement], tabpanel: [object HTMLDivElement] },\n// -\u003e   { index: 2, defaultSelected: false, disabled: false, selected: false, name: \"Customer-Reviews\", tab: [object HTMLLIElement], tabpanel: [object HTMLDivElement] }\n// -\u003e ]\n```\n\n### `selectedIndex`\n\nThe index of the selected element.  **Read only**.\n\nThe value `-1` is returned if no element is selected.\n\n```js\nvar t = new TabEmbed(\"#Product-TabEmbed\");\n\nt.selectedIndex;\n// -\u003e 1\n```\n\n### `selectedElements`\n\nThe set of elemets that are selected. **Read only**.\n\n```js\nvar t = new TabEmbed(\"#Product-TabEmbed\");\n\nt.selectedElements;\n// -\u003e [ … ]\n```\n\n### `element(index)`\n\nGets an element from the elements collection for this component.\n\n```js\nvar t = new TabEmbed(\"#Product-TabEmbed\");\n\nt.element(0);\n// -\u003e { … }\n\nt.element(2);\n// -\u003e undefined\n```\n\n### `namedElement(name)`\n\nGets the element from the elements collection with the specified name.\n\n```js\nvar t = new TabEmbed(\"#Product-TabEmbed\");\n\nt.namedElement(\"Technical-Details\");\n// -\u003e { … }\n\nt.namedElement(\"Custmoer-Reviews\");\n// -\u003e undefined\n```\n\n### `select(element)`\n\nSelects an element from the collection of elements for this component.\n\n```js\nvar t = new TabEmbed(\"#Product-TabEmbed\");\n\nt.select(t.elements[1]);\n\nvar p = t.element(1);\nt.select(p);\n\nvar p = t.namedElement(\"Customer-Reviews\");\nt.select(p);\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F7studio%2Ftabembed","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F7studio%2Ftabembed","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F7studio%2Ftabembed/lists"}