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

chore: Add toolbar example #970

Closed
wants to merge 3 commits into from

Conversation

leonardoelias
Copy link
Contributor

@leonardoelias leonardoelias commented Dec 28, 2021

Adds a "toolbar" example #939.

Toolbar

Screen Shot 2021-12-28 at 23 47 44

Toolbar with menu

Screen Shot 2021-12-29 at 00 40 48

e-2f496bddc296.png">

@vercel
Copy link

vercel bot commented Dec 28, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployments, click below or on the icon next to each commit.

ariakit – ./

🔍 Inspect: https://vercel.com/ariakit/ariakit/3MKRjMnyBiBXkLDrSrx5YpW5dxn9
✅ Preview: https://ariakit-git-fork-leonardoelias-feat-toolbar-ex-ariakit.vercel.app

[Deployment for ccd0a51 failed]

reakit – ./

🔍 Inspect: https://vercel.com/ariakit/reakit/5MgQe1RVfgyn4HHk63yDyb6n9kTR
✅ Preview: Canceled

[Deployment for ccd0a51 canceled]

@codesandbox-ci
Copy link

codesandbox-ci bot commented Dec 28, 2021

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

@leonardoelias leonardoelias changed the title Feat/toolbar ex chore: Add toolbar example Dec 28, 2021
@leonardoelias leonardoelias changed the title chore: Add toolbar example chore: Add toolbar example Dec 28, 2021
@ariakit ariakit deleted a comment from netlify bot Dec 29, 2021
@codecov
Copy link

codecov bot commented Dec 29, 2021

Codecov Report

Merging #970 (ccd0a51) into v2 (1966140) will increase coverage by 19.97%.
The diff coverage is 0.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##               v2     #970       +/-   ##
===========================================
+ Coverage   42.37%   62.35%   +19.97%     
===========================================
  Files         155      160        +5     
  Lines        4113     4133       +20     
  Branches     1160     1159        -1     
===========================================
+ Hits         1743     2577      +834     
+ Misses       2369     1555      -814     
  Partials        1        1               
Impacted Files Coverage Δ
...c/toolbar/__examples__/toolbar-with-menu/index.tsx 0.00% <0.00%> (ø)
...ariakit/src/toolbar/__examples__/toolbar/index.tsx 0.00% <0.00%> (ø)
packages/ariakit/src/tab/tab-state.ts 69.44% <0.00%> (-7.16%) ⬇️
packages/ariakit/src/portal/portal.tsx 57.14% <0.00%> (-0.59%) ⬇️
packages/ariakit/src/tab/tab.ts 97.22% <0.00%> (-0.08%) ⬇️
...kages/ariakit/src/disclosure/disclosure-content.ts 48.93% <0.00%> (ø)
...src/menu/__examples__/menu-item-checkbox/index.tsx 100.00% <0.00%> (ø)
...kages/ariakit/src/form/__examples__/form/index.tsx 100.00% <0.00%> (ø)
...heckbox/__examples__/checkbox-controlled/index.tsx 100.00% <0.00%> (ø)
packages/ariakit/src/composite/composite.ts 91.11% <0.00%> (+0.74%) ⬆️
... and 46 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1966140...ccd0a51. Read the comment docs.

@leonardoelias
Copy link
Contributor Author

hey @diegohaz is this how you were thinking?

}

.button {
@apply
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a way to extend the button?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you mean by extending the button? If we have to override a lot of styles, it's okay not to import the base button example and add everything here.

}

.button svg {
@apply sm:block hidden;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here i am removing the icon when the screen reaches the width of sm. This so as not to break the playground

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That makes sense. We can also allow horizontal scrolling on the playground preview in such cases.

Underline
</ToolbarItem>
<ToolbarSeparator className="toolbar-separator" />
{/* @ts-ignore */}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry about that, but i couldn't resolve it.

const menu = useMenuState({ orientation: "horizontal" });
return (
<>
{/* @ts-ignore */}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry about that, but i couldn't resolve it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the error message? Just let the CI throw it so we can find a solution.

@diegohaz diegohaz changed the title chore: Add toolbar example chore: Add toolbar-menu example Jan 3, 2022
@diegohaz diegohaz changed the title chore: Add toolbar-menu example chore: Add toolbar example Jan 3, 2022
@diegohaz
Copy link
Member

diegohaz commented Jan 3, 2022

Let's work on a single example per PR. You can open another PR for the toolbar-menu example later.

@diegohaz diegohaz mentioned this pull request Jan 3, 2022
69 tasks
@diegohaz diegohaz changed the base branch from v2 to master February 10, 2022 22:44
@stale
Copy link

stale bot commented Aug 12, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Aug 12, 2022
@stale stale bot closed this Sep 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants