Skip to content

Commit

Permalink
Merge pull request #265 from vanessatran-ddi/chore/document-accordion…
Browse files Browse the repository at this point in the history
…-event

chore: add accordion onChange event
  • Loading branch information
vanessatran-ddi authored Nov 13, 2024
2 parents 93997b3 + 2574722 commit 8d0458d
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 10 deletions.
16 changes: 8 additions & 8 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
"prettier": "npx prettier . --write"
},
"dependencies": {
"@abgov/react-components": "5.3.0",
"@abgov/web-components": "1.28.0",
"@abgov/react-components": "5.0.0-alpha.12",
"@abgov/web-components": "1.17.0-alpha.123",
"@faker-js/faker": "^8.3.1",
"highlight.js": "^11.8.0",
"octokit": "^4.0.2",
Expand Down
12 changes: 12 additions & 0 deletions src/routes/components/Accordion.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,18 @@ export default function AccordionPage() {
type: "none | 3xs | 2xs | xs | s | m | l | xl | 2xl | 3xl | 4xl",
description: "Apply margin to the top, right, bottom, and/or left of the component.",
},
{
name: "_change",
lang: "angular",
type: "CustomEvent",
description: "Callback function when accordion heading is clicked.",
},
{
name: "onChange",
lang: "react",
type: "(open: boolean) => void",
description: "Callback function when accordion heading is clicked.",
}
];

function onSandboxChange(bindings: ComponentBinding[], props: Record<string, unknown>) {
Expand Down

0 comments on commit 8d0458d

Please sign in to comment.