Marshall Bowers
b357ae4dc3
Add new Button
and IconButton
components ( #3448 )
...
This PR adds new `Button` and `IconButton` components built on top of
our new button abstractions.
Both of these buttons are built from the common `ButtonLike` base, and
implement the `ButtonCommon` (name TBD) trait in order to provide a
common interface.
There are still some visual tweaks that we'll need to make to the new
buttons, but those should be straightforward to make after we land this.
Release Notes:
- N/A
2023-11-29 17:41:44 -05:00
Marshall Bowers
df5de47a78
Make toggle
method accept impl Into<Option<bool>>
( #3446 )
...
This PR makes the `toggle` method on the various list components accept
an `impl Into<Option<bool>>` instead of just an `Option<bool>`.
This allows a caller with just a `bool` avoid having to wrap the
`Option` themselves.
Release Notes:
- N/A
2023-11-29 16:13:41 -05:00
Conrad Irwin
fb377aed73
Context menu, Dragon Drop, for collab panel ( #3441 )
...
Release Notes:
- N/A
2023-11-29 13:40:46 -07:00
Marshall Bowers
d8ed7c0721
Move GraphicSlot
out of components
module ( #3444 )
...
This PR moves the `GraphicSlot` definition out of the `components`
module, as it doesn't contain a component.
Release Notes:
- N/A
2023-11-29 15:29:33 -05:00
Conrad Irwin
6ab3825ab1
No moar toggleable
2023-11-29 13:25:29 -07:00
Marshall Bowers
e77846d2dc
Rework Toggle
into Toggleable
and ToggleState
2023-11-29 14:33:52 -05:00
Marshall Bowers
6f5cc0af94
Rework Disclosure
component
2023-11-29 14:07:48 -05:00
Marshall Bowers
c7b79c9aef
Remove unnecessary constructor and Clone
derives
2023-11-29 13:38:05 -05:00
Marshall Bowers
390b0d8d56
Reorganize list components
2023-11-29 13:34:50 -05:00
Max Brunsfeld
960ef7116d
Add a context menu to the project panel ( #3393 )
...
This PR adds a context menu to the project panel in Zed2.
* [x] Allow the context menu to extend outside of the project panel's
bounds
* [x] Add keyboard shortcuts to the context menu
* [x] Dismiss the context menu
* [x] when running an action
* [x] when changing selection in the project panel
Release Notes:
NA
2023-11-29 10:04:41 -08:00
Marshall Bowers
3e2c517dd1
Add Disableable
trait ( #3439 )
...
This PR adds a new `Disableable` trait to use for elements that are
capable of being disabled.
Release Notes:
- N/A
2023-11-29 13:01:26 -05:00
Max Brunsfeld
dbfc7d3555
Merge branch 'main' into project-panel-context-menu
2023-11-29 09:45:31 -08:00
Max Brunsfeld
233aac5573
Make DismissEvent a unit struct
...
Co-authored-by: Conrad <conrad@zed.dev>
2023-11-29 09:42:54 -08:00
Marshall Bowers
043cef89eb
Remove unneeded wrapping div
s in ListItem
left content ( #3438 )
...
This PR removes some unneeded wrapping `div`s around the left content in
`ListItem`s.
Release Notes:
- N/A
2023-11-29 12:40:35 -05:00
Max Brunsfeld
ac34229118
Add keyboard control over context menus
...
Co-authored-by: Conrad <conrad@zed.dev>
2023-11-29 09:39:20 -08:00
Marshall Bowers
912c30c05b
Remove unneeded .clone
s
2023-11-29 12:35:39 -05:00
Marshall Bowers
97e6fd295a
Remove unneeded wrapping divs in ListItem
left content
2023-11-29 12:29:48 -05:00
Nate Butler
a8bf0834e6
Button2 – Part1 ( #3420 )
...
## TODO
- [x] Remove `InteractionState`
- [ ] `Selectable` should use `Selection` instead of a boolean
- [x] Clean out ui2 prelude
- [ ] Build out button2 button types
- [ ] Port old buttons
Release Notes:
- N/A
---------
Co-authored-by: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
2023-11-29 12:23:09 -05:00
Conrad Irwin
5fbc60d8da
Inviting/Responding/Creating Channels... etc.
2023-11-28 22:47:04 -07:00
Conrad Irwin
0d4839b973
use the right click event for buttons
2023-11-28 21:14:48 -07:00
Marshall Bowers
e36c7dd301
Remove ID hack in ListItem
( #3431 )
...
This PR removes the ID hack in `ListItem`, since the underlying issue
was fixed in #3430 .
Release Notes:
- N/A
2023-11-28 23:11:29 -05:00
Conrad Irwin
8d1518d70c
Fix stateful elements in Components
...
Previously a component assumed its element was stateless, this was
incorrect!
2023-11-28 20:47:11 -07:00
Max Brunsfeld
77acba9e4c
Right-align key bindings in context menus
...
Remove extra div in `List` that prevented list items from
filling the available space.
Co-authored-by: Marshall <marshall@zed.dev>
2023-11-28 17:23:49 -08:00
Max Brunsfeld
6bf7ad71eb
Show action key bindings in context menus
2023-11-28 16:07:42 -08:00
Conrad Irwin
60ce75c34a
Togglable channels, the greatest since sliced bread
2023-11-28 16:52:12 -07:00
Max Brunsfeld
bcf449d3fe
Add a basic context menu to the project panel
2023-11-28 15:12:46 -08:00
Marshall Bowers
5666066db4
Merge branch 'main' into collab-panel2
2023-11-28 17:07:40 -05:00
Marshall Bowers
ee027bc112
Fix tooltips not showing on IconButton
s ( #3427 )
...
This PR fixes tooltips not showing on `IconButton`s.
The "fix" here is the same hack that we used to fix `on_click` handlers
for `ListItem`s, where we introduce another layer of wrapping with an
element with an ID set.
This PR also adds a story for the `IconButton` so this issue can be
tested/observed in isolation.
Release Notes:
- N/A
2023-11-28 17:01:53 -05:00
Conrad Irwin
a85e0db1f4
More progress on collab panel
2023-11-28 14:40:32 -07:00
Marshall Bowers
64376ad37a
ui2: Reference theme2
and settings2
crates without the 2
( #3424 )
...
This PR updates the `ui2` crate to reference the `theme2` and
`settings2` crates without the `2` the way we do in our other crates.
Release Notes:
- N/A
2023-11-28 15:30:29 -05:00
Nate Butler
b24a3b8fcb
Unused imports
2023-11-28 15:17:09 -05:00
Nate Butler
525fe70de6
Fix missing arrows
2023-11-28 15:15:49 -05:00
Nate Butler
21755c7d20
Update keybinding.rs
2023-11-28 15:12:40 -05:00
Nate Butler
3855413725
Merge branch 'main' into refine-keybindings
2023-11-28 15:12:22 -05:00
Marshall Bowers
070674a4fd
ui2: Unsuppress and fix warnings ( #3423 )
...
This PR unsupresses the warnings in `ui2` and summarily fixes them.
Release Notes:
- N/A
2023-11-28 14:44:19 -05:00
Nate Butler
a9cb6589dd
Update keybinding.rs
2023-11-28 14:40:26 -05:00
Marshall Bowers
874fde09ab
Add inset variant to ListItem
( #3422 )
...
This PR adds an inset variant to the `ListItem` component.
We're now using this inset variant for the `ListItem`s we render in
pickers.
Release Notes:
- N/A
2023-11-28 14:27:19 -05:00
Nate Butler
f33cd3d463
Merge branch 'main' into refine-keybindings
2023-11-28 14:00:09 -05:00
Conrad Irwin
01d3432a40
Merge branch 'main' into collab-panel2
2023-11-28 11:40:58 -07:00
Marshall Bowers
9411898720
Use ListItem
s in the project panel ( #3421 )
...
This PR reworks the project panel to render its items using the
`ListItem` component.
There are a few hacks in here in order to get click handlers working for
the `ListItem`, but we'll want to get these fixed in GPUI.
Release Notes:
- N/A
2023-11-28 13:11:43 -05:00
Marshall Bowers
1ee109cec7
Use ListItem
when rendering picker matches
2023-11-28 10:44:57 -05:00
Piotr Osiewicz
9fb3cb6a69
fixup! Add contact finder, change ui::List's on_click handler signature
2023-11-28 14:37:53 +01:00
Piotr Osiewicz
6c37393dd1
Add contact finder, change ui::List's on_click handler signature
2023-11-28 14:16:51 +01:00
Nate Butler
979ff70196
Update popover.rs
2023-11-27 20:12:20 -05:00
Nate Butler
ca2052b0c1
Merge branch 'main' into completions-styles
2023-11-27 19:22:07 -05:00
Conrad Irwin
4a25fae51e
TEMP
2023-11-27 16:22:01 -07:00
Marshall Bowers
24f3034106
Add ListItem
story ( #3411 )
...
This PR adds a story for the `ListItem` component, so we can work on it
in isolation.
Release Notes:
- N/A
2023-11-27 15:24:41 -05:00
Conrad Irwin
4f885252ab
[Zed2] Collab UI ( #3403 )
...
Release Notes:
- N/A
2023-11-27 12:40:59 -07:00
Marshall Bowers
19ecccb107
Add ListItem
story
2023-11-27 14:20:33 -05:00
Conrad Irwin
82f6f77117
Use editor's overlay implementation
2023-11-27 11:49:51 -07:00