1
0
mirror of https://github.com/bitwarden/browser.git synced 2025-01-30 22:41:33 +01:00
Commit Graph

334 Commits

Author SHA1 Message Date
Nick Krantz
e26670c029
[PM-14422] Vault Carousel (#12791)
* collect tailwind styles from the `libs/vault/*`

- Some unique styles were not showing in storybook

* initial add of carousel component

* initial add of carousel stories

* move carousel button to a standalone component for organization

* add key manager for carousel buttons

* add tab panel role to slide component

* make carousel slide focusable when it does not contain focusable elements

* add aria live to carousel slides

* add labels for carousel slide buttons

* emit slide change event

* move icons to carousel-icons folder

* add barrel file for carousel

* move protected properties

* remove underscore

* allow differing heights of carousel slides

* update interactive styles for the carousel icons

* allow for focus styled on carousel buttons

* fix tests

* fix imports

* add method to render each slide and get the height of the tallest slide

- This avoids consumers having to pass in a height.
- The height of the tallest slide is needed because it will stop the carousel from jumping around as the user scrolls.

* add comment to content property

* remove rem calculation
2025-01-22 08:45:35 -06:00
Oscar Hinton
d820bfb691
[PM-17346] Move A11yTitle and CopyClick to CL (#12936)
* Move A11yTitle and CopyClick to CL
2025-01-20 11:43:10 +01:00
Oscar Hinton
83802fcdc5
Fix i18n import of drawer component (#12932)
Resolves main being broken after merging #12831 due to a new component depending on `I18nPipe`.
2025-01-17 16:01:23 +00:00
Danielle Flinn
23227f5064
[CL-256] Update Figma links in Storybook docs (#12901)
* Update Figma links

updated existing Figma links to point to the new file and added Figma links to components missing them

* Added last missing Figma links
2025-01-17 07:50:20 -08:00
Oscar Hinton
e5f83ff086
[PM-17031] Create UI-common (#12831)
Extract core functionality from `libs/angular` to allow teams to depend on `libs/ui-common` instead.

Moves the following functionality to `ui-common`.
- `I18nPipe`. `libs/angular` still has an old copy but `components` depends on the new variant from `ui-common`.
- `safeProvider`, `SafeProvider` and `SafeInjectionToken`. `libs/angular`re-exports these to avoid needing to update all consumers.
2025-01-17 10:42:31 -05:00
Oscar Hinton
dafeb1492a
Add type=button to stories (#12930) 2025-01-17 14:57:31 +01:00
Will Martin
ea052b9e07
[CL-428] create drawer component (#12812)
* remove private/protected/lifecycle fields from Storybook docs table

* move theme override decorator into util method

* implement base drawer component

* update bit-layout to be drawer container

* create drawer helper components

* expose new APIs to DS barrel file

* write docs

* update docs; add role input

* use host directive instead of service

* clean up logic a tad

* add start slot to story

* update docs

* Apply suggestions from code review

Co-authored-by: Victoria League <vleague@bitwarden.com>

* update docs

* Update libs/components/src/drawer/drawer.mdx

Co-authored-by: Victoria League <vleague@bitwarden.com>

* update docs / stories

* add non text element to drawer

---------

Co-authored-by: Victoria League <vleague@bitwarden.com>
2025-01-16 15:43:04 -05:00
renovate[bot]
62e879940c
[deps] SM: Update typescript-eslint monorepo to v8 (major) (#10601)
* [deps] SM: Update typescript-eslint monorepo to v8

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Hinton <hinton@users.noreply.github.com>
Co-authored-by: Daniel James Smith <djsmith85@users.noreply.github.com>
2025-01-14 11:23:59 -05:00
Victoria League
e568a7a812
[CL-524] Ignore kitchen sink virtual scroll story (#12858) 2025-01-14 11:03:58 -05:00
Victoria League
8062475044
[PM-16243] Allow users to collapse extension sections (#12756) 2025-01-13 10:37:26 -05:00
Oscar Hinton
db84ccf935
[PM-16838] Forbid imports containing /src/ (#12744)
Forbids bad imports containing /src/.
2025-01-10 10:37:34 -05:00
Nick Krantz
fa61928daf
[CL] add ToastVariant to CL barrel file (#12804) 2025-01-10 09:58:47 -05:00
Oscar Hinton
653b730969
[PM-16872] Update libs to use explicit dependencies (#12770)
Update all libs to use explicit dependencies rather than relying on tsconfig.libs.json. This allows us to more easily understand the dependencies between libs and prevent users from accidentally adding new dependencies.

We still use tsconfig.libs (now renamed tsconfig.spec) for tests.
2025-01-10 11:21:38 +01:00
Thomas Avery
8cfa30acb5
[PM-16889] Add KM lib to tailwind configs (#12783)
Add KM lib to tailwind configs
2025-01-09 13:07:26 -06:00
Oscar Hinton
9ca3d0653d
Fix strict typescript for Component Library stories (#12423)
Fixing some low hanging fruits for moving CL to strict typescript.

This primarily removes the types from args since TS infers them differently. We previously needed them since storybook would use any for args but now provides proper typings
2025-01-07 17:28:35 +01:00
Kyle Spearrin
05d373d070
turn off autocomplete for browser search input (#12679) 2025-01-03 14:51:54 -05:00
Victoria League
c07454342d
[PM-16675] Prevent scrollbar from appearing on each send item (#12666) 2025-01-03 09:41:18 -05:00
Victoria League
a95427eee0
[CL-524] Ignore flaky elements in Chromatic tests (#12561) 2024-12-30 16:42:53 -05:00
Victoria League
6539f06654
[CL-135] Fix import statement for standalone component (#12589) 2024-12-30 14:46:29 -05:00
Victoria League
1f4972fcb8
[PM-16102] Prevent item action height overflow (#12588) 2024-12-30 09:10:42 -05:00
Victoria League
395258d63e
[PM-16102] Add min width on interactive badges (#12514) 2024-12-23 12:08:52 -05:00
Victoria League
64166a9354
[PM-16102] Increase clickable area for bit-item actions (#12450) 2024-12-20 14:03:50 -05:00
Victoria League
6eb30c98c4
Fix imports for standalone component stories (#12464) 2024-12-18 14:25:03 -05:00
Oscar Hinton
5a582dfc6f
[CL-135] Migrate component library to standalone components (#12389)
* Migrate component library to standalone components

* Fix tests
2024-12-17 17:29:48 -05:00
renovate[bot]
e1447a90e3
[deps] Design System: Update ngx-toastr to v19 (#10594)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Victoria League <vleague@bitwarden.com>
2024-12-17 10:08:19 -05:00
Matt Gibson
6132df395c
Add strict to missed components tsconfig (#12429) 2024-12-16 16:33:01 +00:00
Victoria League
4daba832a2
[CL-351] Prevent tw-group styling conflicts by namespacing (#12261) 2024-12-09 15:13:42 -05:00
Matt Gibson
9c1e2ebd67
Typescript-strict-plugin (#12235)
* Use typescript-strict-plugin to iteratively turn on strict

* Add strict testing to pipeline

Can be executed locally through either `npm run test:types` for full type checking including spec files, or `npx tsc-strict` for only tsconfig.json included files.

* turn on strict for scripts directory

* Use plugin for all tsconfigs in monorepo

vscode is capable of executing tsc with plugins, but uses the most relevant tsconfig to do so. If the plugin is not a part of that config, it is skipped and developers get no feedback of strict compile time issues. These updates remedy that at the cost of slightly more complex removal of the plugin when the time comes.

* remove plugin from configs that extend one that already has it

* Update workspace settings to honor strict plugin

* Apply strict-plugin to native message test runner

* Update vscode workspace to use root tsc version

* `./node_modules/.bin/update-strict-comments` 🤖

This is a one-time operation. All future files should adhere to strict type checking.

* Add fixme to `ts-strict-ignore` comments

* `update-strict-comments` 🤖

repeated for new merge files
2024-12-09 20:58:50 +01:00
Victoria League
0906c503e1
[CL-522] Reduce font size for checkbox and radio labels (#12251) 2024-12-09 14:10:14 -05:00
Victoria League
eac5e63f2f
[CL-513] Fix lifecycle order for toggle title attribute (#12152) 2024-11-26 11:10:43 -05:00
Will Martin
bb0912154d
[CL-508] extension width setting (#12040) 2024-11-25 14:43:31 -05:00
Thomas Rittson
365c7dd65e
[CL] add hideIfEmpty input to bit-nav-group (#12046) 2024-11-20 13:06:07 -05:00
Nick Krantz
ca839b3d80
[PM-14019] Toggle Vault Filters (#11929)
* move vault headings to their own component

* update aria-label to bind to the data attribute

* move vault headings to the vault-v2 folder

* integrate disclosure trigger to hide vault filters

* remove built in margin on search component

- spacing will be managed by the parent component

* add event emitter so consuming components can know when disclosure status has changed

* add filter badge when filters are selected and the filters are hidden

* persist filter visibility state to disk

* add supporting text for the filter button

* remove extra file

* only read from stored state on component launch.

- I noticed delays when trying to use stored state as the source of truth

* use two-way data binding for change event

* update vault headers to use two way data binds from disclosure component

- also adjust consuming changes

* add border thickness

* add ticket to the FIXME

* move number of filters observable into service

* move state coordination into filter service

* only expose state and update methods from filter service

* simplify observables to avoid needed state lifecycle methods

* remove comment

* fix test imports

* update badge colors

---------

Co-authored-by: Matt Bishop <mbishop@bitwarden.com>
2024-11-19 11:49:42 -06:00
Will Martin
a07b072196
[CL-499][PM-14020] compact mode (#11796) 2024-11-18 16:35:49 -05:00
Merissa Weinstein
c51b9233b3
decrease bit-item ring size (#12017) 2024-11-18 09:48:27 -06:00
Victoria League
3b5b2d6bd6
[CL-265] CL/extension refresh feature branch (#8696)
* [CL-245] Update palette to new light and dark theme colors (#8633)

* [CL-245] Add new color swatches to storybook (#8697)

* [CL-238] update typography (#8997)

* [CL-230] [CL-296] Update button styles (#9345)

* [CL-237] Update menu styles for extension refresh (#9525)

* [CL-267] Add 100-level color variants and update primary-600 (#9550)

* [CL-286] Update badge to use focus-visible instead of focus (#9551)

* [CL-250] Update badge styles for extension refresh (#9572)

* [CL-234] callout style refresh (#9920)

* [CL-233] Update form field styles (#9776)

* [CL-239][CL-251][CL-342] dialog style refresh (#10096)

* [CL-239] simple dialog style refresh

* [CL-342] fix text overflow in dialog; add story

* [CL-244] readonly fields (#10164)

* [CL-352] Fix Angular errors related to form element changes (#10211)

* [CL-273] Update styles for checkbox and form control (#10146)

* [CL-274] Update styling for radio button (#10333)

* [CL-338] Remove extra space in item content when end slot is empty (#10350)

* [CL-377] Fix extension style conflict for input background (#10351)

* [CL-271] Update styles for toggle (#10377)

* [CL-381] Update spacing around form elements (#10432)

* [CL-229] Update icon button styles (#10405)

* [CL-380] Remove hover state from disabled form fields (#10639)

* [CL-405] Allow toggle group input to be full width (#10658)

* [CL-389] Exclude end slot label content from truncation (#10508)

* [CL-383] Remove manual focus when password toggle is clicked (#10749)

* [CL-278][CL-391] misc bit-item style fixes (#10758)

* [CL-391] use pointer cursor on hover when link or button

* [CL-210] Change base font size from 14px to 16px (#10779)

* [CL-291] Finalize styling for chip select (#10771)

* [CL-257] update banner component styles (#10766)

* [CL-443] Fix sizing issues (#10893)

* [CL-445] Fix small sizing and spacing issues (#10962)

* [CL-382] Reduce element shifting on readonly hover (#10956)

* [CL-396] Update theme colors to new hexes (#10968)

* [CL-395] Remove text headers color (#10997)

* [CL-404] Switch to primary-600 for all focus indicators (#11015)

* [CL-397] Remove primary-500 (#11036)

* [CL-447] Ensure DM Sans displays correctly at all font weights (#11041)

* [CL-448] Scrollbar Styles (#11111)

* CL-252/update toast (#10996)

* [CL-275] Update link styles (#11174)

* [CL-446] Update hover state for unselected chip selects (#11172)

* [CL-454] Improve color a11y for toast and banner interactive elements (#11200)

* [CL-457] Center input text for select and multiselect (#11239)

* [CL-455] Do not use responsive margin for sections in dialogs or extension (#11243)

* [CL-459] Fix chip behavior when opening menu while item is selected (#11227)

* [CL-388] Update vertical nav colors for new palette (#11226)

* scope styled scrollbar to only select elements (#11247)

* edit radio buttons to be block inputs and update spacing (#11291)

* [CL-453] Fix multiselect chip spacing and truncation (#11300)

* [PM-11131] Prevent duplicated sr labels on form field icon buttons (#11383)

* [CL-303] Prevent chip menu from running offscreen (#11348)

* [CL-476] Fix DM Sans font on Windows (#11409)

* implements scrollbar styles for firefox/chrome and safari (#11447)

* [CL-472] Fix search background color in extension (#11466)

* [CL-481] Style updates for bit-item, bit-card, and primary-100 (#11473)

* [CL-478] Remove underline on hover for most components (#11477)

* [CL-477] Remove focus styles for readonly input (#11510)

* [CL-487] Fix vault items virtual scroll height (#11581)

* [PM-8625] Increase popup width (#11686)

* [CL-494] Wrap long words in toggle group (#11659)

* [CL-13820] Add class to remove link underline (#11762)

* [CL-435] Prevent Windows extension from shifting (#11851)

* [CL-503] Add notification color variables (#11802)

* [PM-14043] Update size of toggle group label to fit more content (#11881)

* [CL-498] Set chip menu width minimum to chip select width (#11905)

---------

Co-authored-by: Will Martin <contact@willmartian.com>
Co-authored-by: Oscar Hinton <Hinton@users.noreply.github.com>
Co-authored-by: Nick Krantz <125900171+nick-livefront@users.noreply.github.com>
Co-authored-by: Merissa Weinstein <merissa.k.weinstein@gmail.com>
Co-authored-by: Danielle Flinn <43477473+danielleflinn@users.noreply.github.com>
2024-11-15 09:21:17 -05:00
Victoria League
e8dac0cc12
[CL-500] Add disclosure component and directive (#11865) 2024-11-07 16:54:49 -05:00
SmithThe4th
faf7e3d315
[PM-11201][CL-507] Add the ability to sort by Name, Group, and Permission within the collection and item tables (#11453)
* Added sorting to vault, name, permission and group

Added default sorting

* Fixed import

* reverted test on template

* Only add sorting functionality to admin console

* changed code order

* Fixed leftover test for sortingn

* Fixed reference

* sort permissions by ascending order

* Fixed bug where a collection had multiple groups and sorting alphbatically didn't happen correctly all the time

* Fixed bug whne creating a new cipher item

* Introduced fnFactory to create a sort function with direction provided

* Used new sort function to make collections always remain at the top and ciphers below

* extracted logic to always sort collections at the top

Added similar sorting to sortBygroup

* removed org vault check

* remove unused service

* Sort only collections

* Got rid of sortFn factory in favour of passing the direction as an optional parameter

* Removed tenary

* get cipher permissions

* Use all collections to filter collection ids

* Fixed ascending and descending issues

* Added functionality to default sort in descending order

* default sort permissions in descending order

* Refactored setActive to not pass direction as a paramater
2024-11-07 10:10:15 -05:00
Alec Rippberger
619651ca55
[PM-13818] Allow user to edit self-hosted url during registration (#11790)
* Trigger self hosted settings dialog on select close

* Simplify triggering self hosted env config dialog

* Always emit selected value

* Update variable naming of lastSelectedValue to userSelectedValue to better reflect purpose

* Add comment for userSelectedValue variable

* Remove userSelectedValue and simply emit a closed event

* Remove passing selectedRegion in closed event
2024-11-06 13:17:59 -06:00
Oscar Hinton
cd79457349
[PM-4347] Upgrade angular to 17 (#11031)
Upgrade angular to 17
2024-11-04 11:51:43 -05:00
Jordan Aasen
18f7d64a6d
[PM-14038] - priority applications UI (#11723)
* priority applications UI

* add security icon
2024-10-30 14:25:06 -04:00
Bernd Schoolmann
b486fcc689
[Pm-13097] Rename cryptoservice to keyservice and move it to km ownership (#11358)
* Rename cryptoservice to keyservice

* Rename cryptoservice to keyservice

* Move key service to key management ownership

* Remove accidentally added file

* Fix cli build

* Fix browser build

* Run prettier

* Fix builds

* Fix cli build

* Fix tests

* Fix incorrect renames

* Rename webauthn-login-crypto-service

* Fix build errors due to merge conflicts

* Fix linting
2024-10-24 19:41:30 +02:00
Oscar Hinton
9b474264e6
[CL-343] Create a new table component for virtual scrolling (#10113)
This creates a new component called bit-table-scroll as it's a breaking change in how tables works. We could probably conditionally support both behaviors in the existing table component if we desire.

Rather than iterating the rows in the consuming component, we now need to define a row definition, bitRowDef which provides access to the rows data through angular let- syntax. This allows the table component to own the behaviour which is needed in order to use the cdkVirtualFor directive which must be inside the cdk-virtual-scroll-viewport component.
2024-10-22 21:51:45 +02:00
Jared Snider
2605c03c81
Update Icon Docs to include information on viewbox scaling (#11613) 2024-10-18 12:14:29 -04:00
Jared Snider
a5f856da2a
Component Library - Add Icon documentation (#11571)
* Add Icon documentation

* Add 7th bullet

* Icon docs - add context on how to go from hex values to appropriate tailwind classes.

* 7th bullet needs bold to look right

* Add color icon per suggestion
2024-10-17 10:47:08 -04:00
Victoria League
988c2b69e0
[CL-471] Update lock icon and others (#11508) 2024-10-11 16:12:49 -04:00
Nick Krantz
e2275ad0bc
[PM-12776] Draggable Items within a dialog (#11396)
* increase z-index `cdk-drag-preview` so it displays on top of modals/dialogs when draggable elements are within them

* update comment overlay z-index and add ticket number

* update comment
2024-10-09 12:05:31 -05:00
Victoria League
b149db9f4d
[CL-458] Exclude badges from truncation and vertically center content (#11262) 2024-09-30 11:45:51 -04:00
Victoria League
1262623fac
[CL-451] Add option for full width chip select (#11135) 2024-09-20 09:52:12 -04:00
Victoria League
eec84d893d
[CL-439] Improve keyboard and visual a11y for chip select (#11112) 2024-09-19 13:49:00 -04:00