Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overlay component #1998

Merged
merged 31 commits into from
May 10, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
a92f659
Add styles, documentation, and storybook story for the new dialog com…
Mar 25, 2022
013904b
Stylelint auto-fixes
actions-user Mar 25, 2022
a2ac939
Create slow-poets-mate.md
langermank Mar 30, 2022
00b8195
Update slow-poets-mate.md
langermank Mar 30, 2022
8603de5
update namespace
langermank Apr 14, 2022
f009094
Stylelint auto-fixes
actions-user Apr 14, 2022
5c1a056
menu specifics
langermank Apr 19, 2022
e38373c
starting over
langermank Apr 22, 2022
bd44e26
a new paradigm
langermank Apr 22, 2022
9f446cd
fully responsive
langermank Apr 22, 2022
fa39835
push for testing
langermank Apr 22, 2022
33a4670
auto width, visibility hidden
langermank Apr 25, 2022
c061401
Overlay stories
langermank Apr 26, 2022
06a2254
dialog stories
langermank Apr 26, 2022
f8c787f
Merge branch 'main' into accessibility/issues/925/dialog-component
langermank Apr 26, 2022
10345a3
cleanup
langermank Apr 26, 2022
2dcdfda
Merge branch 'accessibility/issues/925/dialog-component' of https://g…
langermank Apr 26, 2022
8007f19
remove popover
langermank Apr 26, 2022
8dd553e
remove unused import
langermank Apr 26, 2022
4b9270e
docs update
langermank Apr 26, 2022
81d3bb2
min() to the rescue!
langermank Apr 26, 2022
e0a3bf5
thin scrollbar?
langermank Apr 26, 2022
80a021f
remove comment
langermank Apr 27, 2022
878d6d7
Update src/overlay/overlay.scss
langermank Apr 27, 2022
35730cf
address feedback
langermank Apr 27, 2022
a58a244
Merge branch 'accessibility/issues/925/dialog-component' of https://g…
langermank Apr 27, 2022
2257246
handle form elements
langermank May 4, 2022
ada0d64
test permissions
langermank May 4, 2022
b94a0b8
Merge branch 'main' into accessibility/issues/925/dialog-component
langermank May 10, 2022
b9747f7
lint
langermank May 10, 2022
ea44985
Merge branch 'accessibility/issues/925/dialog-component' of https://g…
langermank May 10, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/slow-poets-mate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/css": minor
---

Styles for the new Dialog Component
58 changes: 58 additions & 0 deletions docs/content/components/dialog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---
title: Dialog
path: components/dialog
status: Alpha
source: 'https://github.com/github/github/tree/master/app/assets/stylesheets/experiments/modal-dialog.scss'
bundle: dialog
---

Please note that the `<div>` element with `id="fake-container"` is not included in the component.

```html live
<div id="fake-container" style="height: 400px;">
<button class="btn"><span>Open dialog</span></button>
<div
id="overlay-backdrop"
class="Overlay-backdrop Overlay-backdrop--center"
role="dialog"
aria-labelledby="title-id"
aria-describedby="description-id"
data-focus-trap="active"
>
<div
class="Overlay Overlay--width-medium Overlay--height-medium Overlay--motion-scaleFade"
data-focus-trap="active"
open=""
>
<header class="Overlay-header">
<div class="Overlay-headerContentWrap">
<div class="Overlay-titleWrap">
<h1 id="title-id" class="Overlay-title">This is the title of the dialog</h1>
<h2 id="description-id" class="Overlay-description">This is the subtitle of the dialog</h2>
</div>
<div class="Overlay-actionWrap">
<button class="Overlay-closeButton" aria-label="Close">
<svg aria-hidden="true" viewBox="0 0 16 16" width="16" height="16" fill="currentColor">
<path
fill-rule="evenodd"
d="M3.72 3.72a.75.75 0 011.06 0L8 6.94l3.22-3.22a.75.75 0 111.06 1.06L9.06 8l3.22 3.22a.75.75 0 11-1.06 1.06L8 9.06l-3.22 3.22a.75.75 0 01-1.06-1.06L6.94 8 3.72 4.78a.75.75 0 010-1.06z"
></path>
</svg>
</button>
</div>
</div>
</header>
<div class="Overlay-body">
This is the body of the dialogThis is the body of the dialogThis is the body of the dialog This is the body of
the dialog This is the body of the dialog This is the body of the dialog This is the body of the dialog This is
the body of the dialog This is the body of the dialog
</div>
<footer class="Overlay-footer Overlay-footer--divided Overlay-footer--alignEnd">
<button class="btn"><span>Continue</span></button>
</footer>
</div>
</div>
</div>
```

[aria attributes]: https://www.w3.org/TR/html-aria/#allowed-aria-roles-states-and-properties
Loading