@box/blueprint-web 17.11.3 → 17.11.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12394,7 +12394,9 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12394
12394
  .bp_menu_combobox_module_menuCloseButton--88105{
12395
12395
  grid-area:close;
12396
12396
  }
12397
- .bp_notification_module_viewport--c9108{
12397
+
12398
+ .bp_notification_module_viewport--3428d{
12399
+ --notification-width:35rem;
12398
12400
  --notification-viewport-space:var(--space-4);
12399
12401
  --notification-viewport-item-spacing:var(--space-3);
12400
12402
  all:unset;
@@ -12409,10 +12411,11 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12409
12411
  z-index:var(--z-index-notification);
12410
12412
  }
12411
12413
 
12412
- .bp_notification_module_root--c9108[data-modern=false]{
12414
+ .bp_notification_module_root--3428d[data-modern=false]{
12413
12415
  --notification-padding-vertical:var(--space-3);
12414
12416
  --notification-padding-horizontal:var(--space-4);
12415
12417
  --notification-item-spacing:var(--space-3);
12418
+ --notification-item-row-spacing:var(--space-4);
12416
12419
  --notification-radius:var(--radius-3);
12417
12420
  --notification-border:var(--border-2);
12418
12421
  --notification-shadow:var(--dropshadow-3);
@@ -12430,7 +12433,7 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12430
12433
  --notification-icon-size:var(--size-8);
12431
12434
  --notification-icon-margin:0.375rem;
12432
12435
  }
12433
- .bp_notification_module_root--c9108[data-modern=false] .bp_notification_module_text--c9108{
12436
+ .bp_notification_module_root--3428d[data-modern=false] .bp_notification_module_text--3428d{
12434
12437
  font-family:var(--body-default-bold-font-family);
12435
12438
  font-size:var(--body-default-bold-font-size);
12436
12439
  font-weight:var(--body-default-bold-font-weight);
@@ -12440,10 +12443,11 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12440
12443
  text-transform:var(--body-default-bold-text-case);
12441
12444
  }
12442
12445
 
12443
- .bp_notification_module_root--c9108[data-modern=true]{
12446
+ .bp_notification_module_root--3428d[data-modern=true]{
12444
12447
  --notification-padding-vertical:var(--bp-space-030);
12445
12448
  --notification-padding-horizontal:var(--bp-space-040);
12446
12449
  --notification-item-spacing:var(--bp-space-030);
12450
+ --notification-item-row-spacing:var(--bp-space-040);
12447
12451
  --notification-radius:var(--bp-radius-16);
12448
12452
  --notification-border:var(--bp-border-02);
12449
12453
  --notification-shadow:var(--dropshadow-3);
@@ -12463,7 +12467,7 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12463
12467
  --notification-icon-size:var(--bp-size-080);
12464
12468
  --notification-icon-margin:0.375rem;
12465
12469
  }
12466
- .bp_notification_module_root--c9108[data-modern=true] .bp_notification_module_text--c9108{
12470
+ .bp_notification_module_root--3428d[data-modern=true] .bp_notification_module_text--3428d{
12467
12471
  font-family:var(--bp-font-font-family), -apple-system, BlinkMacSystemFont, "San Francisco", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
12468
12472
  font-size:var(--bp-font-size-05);
12469
12473
  font-style:normal;
@@ -12471,7 +12475,7 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12471
12475
  letter-spacing:var(--bp-font-letter-spacing-01);
12472
12476
  line-height:var(--bp-font-line-height-04);
12473
12477
  }
12474
- :where(body.is-inter-font) .bp_notification_module_root--c9108[data-modern=true] .bp_notification_module_text--c9108{
12478
+ :where(body.is-inter-font) .bp_notification_module_root--3428d[data-modern=true] .bp_notification_module_text--3428d{
12475
12479
  font-family:"Inter Variable", -apple-system, BlinkMacSystemFont, "San Francisco", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
12476
12480
  font-size:.875rem;
12477
12481
  font-style:normal;
@@ -12482,145 +12486,115 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12482
12486
  text-transform:none;
12483
12487
  }
12484
12488
 
12485
- .bp_notification_module_root--c9108[data-modern=true].bp_notification_module_info--c9108{
12489
+ .bp_notification_module_root--3428d[data-modern=true].bp_notification_module_info--3428d{
12486
12490
  background:linear-gradient(0deg, var(--notification-background-info) 0, var(--notification-background-info) 100%), var(--notification-background-overlay);
12487
12491
  }
12488
- .bp_notification_module_root--c9108[data-modern=true].bp_notification_module_success--c9108{
12492
+ .bp_notification_module_root--3428d[data-modern=true].bp_notification_module_success--3428d{
12489
12493
  background:linear-gradient(0deg, var(--notification-background-success) 0, var(--notification-background-success) 100%), var(--notification-background-overlay);
12490
12494
  }
12491
- .bp_notification_module_root--c9108[data-modern=true].bp_notification_module_warning--c9108{
12495
+ .bp_notification_module_root--3428d[data-modern=true].bp_notification_module_warning--3428d{
12492
12496
  background:linear-gradient(0deg, var(--notification-background-warning) 0, var(--notification-background-warning) 100%), var(--notification-background-overlay);
12493
12497
  }
12494
- .bp_notification_module_root--c9108[data-modern=true].bp_notification_module_error--c9108{
12498
+ .bp_notification_module_root--3428d[data-modern=true].bp_notification_module_error--3428d{
12495
12499
  background:linear-gradient(0deg, var(--notification-background-error) 0, var(--notification-background-error) 100%), var(--notification-background-overlay);
12496
12500
  }
12497
12501
 
12498
- .bp_notification_module_root--c9108{
12502
+ .bp_notification_module_root--3428d{
12499
12503
  backdrop-filter:blur(var(--notification-background-blur));
12500
12504
  border:var(--notification-border) solid;
12501
12505
  border-radius:var(--notification-radius);
12502
12506
  box-shadow:var(--notification-shadow);
12507
+ box-sizing:border-box;
12503
12508
  display:flex;
12504
- max-width:288px;
12509
+ max-width:min(var(--notification-width), 100vw - var(--bp-space-040, var(--space-4)) * 2);
12505
12510
  padding:var(--notification-padding-vertical) var(--notification-padding-horizontal);
12506
- width:max-content;
12507
- }
12508
- @media (width > 374px){
12509
- .bp_notification_module_root--c9108{
12510
- max-width:343px;
12511
- }
12511
+ width:min(var(--notification-width), 100vw - var(--bp-space-040, var(--space-4)) * 2);
12512
12512
  }
12513
- @media (width > 767px){
12514
- .bp_notification_module_root--c9108{
12515
- max-width:728px;
12516
- }
12517
- }
12518
- @media (width > 1023px){
12519
- .bp_notification_module_root--c9108{
12520
- max-width:848px;
12521
- }
12522
- }
12523
- @media (width > 1219px){
12524
- .bp_notification_module_root--c9108{
12525
- max-width:896px;
12526
- }
12527
- }
12528
- .bp_notification_module_root--c9108 .bp_notification_module_container--c9108{
12513
+ .bp_notification_module_root--3428d .bp_notification_module_container--3428d{
12529
12514
  align-items:flex-start;
12530
12515
  display:flex;
12531
12516
  gap:var(--notification-item-spacing);
12517
+ min-width:0;
12532
12518
  width:100%;
12533
12519
  }
12534
- @media (width > 767px){
12535
- .bp_notification_module_root--c9108 .bp_notification_module_container--c9108{
12536
- align-items:center;
12537
- }
12538
- }
12539
- .bp_notification_module_root--c9108 .bp_notification_module_mobileContainer--c9108{
12540
- align-items:left;
12520
+ .bp_notification_module_root--3428d .bp_notification_module_messageRow--3428d{
12521
+ align-items:center;
12541
12522
  display:flex;
12542
- flex-direction:column;
12523
+ flex:1 1 auto;
12524
+ flex-wrap:wrap;
12525
+ min-width:0;
12543
12526
  overflow:hidden;
12544
12527
  width:100%;
12545
12528
  }
12546
- @media (width > 767px){
12547
- .bp_notification_module_root--c9108 .bp_notification_module_mobileContainer--c9108{
12548
- align-items:center;
12549
- flex-direction:row;
12550
- }
12529
+ .bp_notification_module_root--3428d .bp_notification_module_withButtons--3428d{
12530
+ gap:var(--notification-item-row-spacing) var(--notification-item-spacing);
12551
12531
  }
12552
- .bp_notification_module_root--c9108 .bp_notification_module_withButtons--c9108{
12553
- gap:var(--notification-item-spacing);
12554
- }
12555
- .bp_notification_module_root--c9108.bp_notification_module_info--c9108{
12532
+ .bp_notification_module_root--3428d.bp_notification_module_info--3428d{
12556
12533
  background:var(--notification-background-info);
12557
12534
  border-color:var(--notification-border-color-info);
12558
12535
  }
12559
- .bp_notification_module_root--c9108.bp_notification_module_success--c9108{
12536
+ .bp_notification_module_root--3428d.bp_notification_module_success--3428d{
12560
12537
  background:var(--notification-background-success);
12561
12538
  border-color:var(--notification-border-color-success);
12562
12539
  }
12563
- .bp_notification_module_root--c9108.bp_notification_module_warning--c9108{
12540
+ .bp_notification_module_root--3428d.bp_notification_module_warning--3428d{
12564
12541
  background:var(--notification-background-warning);
12565
12542
  border-color:var(--notification-border-color-warning);
12566
12543
  }
12567
- .bp_notification_module_root--c9108.bp_notification_module_error--c9108{
12544
+ .bp_notification_module_root--3428d.bp_notification_module_error--3428d{
12568
12545
  background:var(--notification-background-error);
12569
12546
  border-color:var(--notification-border-color-error);
12570
12547
  }
12571
- .bp_notification_module_root--c9108:focus-visible{
12548
+ .bp_notification_module_root--3428d:focus-visible{
12572
12549
  box-shadow:0 0 0 var(--border-1, 1px) var(--background-background), 0 0 0 var(--border-3) var(--notification-outline-focus);
12573
12550
  outline:none;
12574
12551
  }
12575
- .bp_notification_module_root--c9108 .bp_notification_module_typeIconContainer--c9108{
12552
+ .bp_notification_module_root--3428d .bp_notification_module_typeIconContainer--3428d{
12576
12553
  align-items:center;
12577
12554
  display:flex;
12578
12555
  height:var(--notification-icon-size);
12579
12556
  justify-content:center;
12580
12557
  width:var(--notification-icon-size);
12581
12558
  }
12582
- .bp_notification_module_root--c9108 .bp_notification_module_typeIconContainer--c9108 .bp_notification_module_typeIcon--c9108{
12559
+ .bp_notification_module_root--3428d .bp_notification_module_typeIconContainer--3428d .bp_notification_module_typeIcon--3428d{
12583
12560
  flex-shrink:0;
12584
12561
  margin:var(--notification-icon-margin);
12585
12562
  }
12586
- .bp_notification_module_root--c9108 .bp_notification_module_text--c9108{
12563
+ .bp_notification_module_root--3428d .bp_notification_module_text--3428d{
12587
12564
  align-items:center;
12588
12565
  color:var(--notification-text-color);
12589
12566
  display:flex;
12567
+ flex:1 1 auto;
12590
12568
  gap:var(--notification-item-spacing);
12591
12569
  min-height:var(--notification-text-container-height);
12570
+ min-width:0;
12592
12571
  overflow:hidden;
12593
12572
  }
12594
- .bp_notification_module_root--c9108 .bp_notification_module_text--c9108 > div{
12573
+ .bp_notification_module_root--3428d .bp_notification_module_text--3428d > div{
12595
12574
  overflow:hidden;
12596
12575
  overflow-wrap:break-word;
12597
12576
  }
12598
- .bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108{
12577
+ .bp_notification_module_root--3428d .bp_notification_module_contentButtonSection--3428d{
12599
12578
  display:flex;
12579
+ flex:0 0 auto;
12600
12580
  gap:var(--notification-item-spacing);
12601
- margin-left:0;
12602
- }
12603
- @media (width > 767px){
12604
- .bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108{
12605
- margin-left:auto;
12606
- }
12607
12581
  }
12608
- .bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108 .bp_notification_module_contentButtons--c9108{
12582
+ .bp_notification_module_root--3428d .bp_notification_module_contentButtonSection--3428d .bp_notification_module_contentButtons--3428d{
12609
12583
  display:flex;
12610
12584
  gap:var(--notification-item-spacing);
12611
12585
  }
12612
- .bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108 .bp_notification_module_contentButtons--c9108 a,.bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108 .bp_notification_module_contentButtons--c9108 button{
12586
+ .bp_notification_module_root--3428d .bp_notification_module_contentButtonSection--3428d .bp_notification_module_contentButtons--3428d a,.bp_notification_module_root--3428d .bp_notification_module_contentButtonSection--3428d .bp_notification_module_contentButtons--3428d button{
12613
12587
  cursor:pointer;
12614
12588
  }
12615
- .bp_notification_module_root--c9108 .bp_notification_module_closeButtonSection--c9108{
12589
+ .bp_notification_module_root--3428d .bp_notification_module_closeButtonSection--3428d{
12616
12590
  display:flex;
12617
12591
  gap:var(--notification-item-spacing);
12618
12592
  margin-left:auto;
12619
12593
  }
12620
- .bp_notification_module_root--c9108 .bp_notification_module_closeButtonSection--c9108 .bp_notification_module_closeButton--c9108{
12594
+ .bp_notification_module_root--3428d .bp_notification_module_closeButtonSection--3428d .bp_notification_module_closeButton--3428d{
12621
12595
  align-self:center;
12622
12596
  }
12623
- .bp_notification_module_root--c9108 .bp_notification_module_closeButtonSection--c9108 .bp_notification_module_closeButton--c9108 svg *{
12597
+ .bp_notification_module_root--3428d .bp_notification_module_closeButtonSection--3428d .bp_notification_module_closeButton--3428d svg *{
12624
12598
  fill:currentcolor;
12625
12599
  }
12626
12600
  .bp_popover_module_popoverContentContainer--6fc5b .bp_popover_module_popoverCard--6fc5b .bp_popover_module_popoverMainContent--6fc5b,.bp_popover_module_popoverContentContainer--6fc5b.bp_popover_module_accessibilitySmallBreakpoint--6fc5b .bp_popover_module_popoverCard--6fc5b .bp_popover_module_popoverScrollContainer--6fc5b{
@@ -12394,7 +12394,9 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12394
12394
  .bp_menu_combobox_module_menuCloseButton--88105{
12395
12395
  grid-area:close;
12396
12396
  }
12397
- .bp_notification_module_viewport--c9108{
12397
+
12398
+ .bp_notification_module_viewport--3428d{
12399
+ --notification-width:35rem;
12398
12400
  --notification-viewport-space:var(--space-4);
12399
12401
  --notification-viewport-item-spacing:var(--space-3);
12400
12402
  all:unset;
@@ -12409,10 +12411,11 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12409
12411
  z-index:var(--z-index-notification);
12410
12412
  }
12411
12413
 
12412
- .bp_notification_module_root--c9108[data-modern=false]{
12414
+ .bp_notification_module_root--3428d[data-modern=false]{
12413
12415
  --notification-padding-vertical:var(--space-3);
12414
12416
  --notification-padding-horizontal:var(--space-4);
12415
12417
  --notification-item-spacing:var(--space-3);
12418
+ --notification-item-row-spacing:var(--space-4);
12416
12419
  --notification-radius:var(--radius-3);
12417
12420
  --notification-border:var(--border-2);
12418
12421
  --notification-shadow:var(--dropshadow-3);
@@ -12430,7 +12433,7 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12430
12433
  --notification-icon-size:var(--size-8);
12431
12434
  --notification-icon-margin:0.375rem;
12432
12435
  }
12433
- .bp_notification_module_root--c9108[data-modern=false] .bp_notification_module_text--c9108{
12436
+ .bp_notification_module_root--3428d[data-modern=false] .bp_notification_module_text--3428d{
12434
12437
  font-family:var(--body-default-bold-font-family);
12435
12438
  font-size:var(--body-default-bold-font-size);
12436
12439
  font-weight:var(--body-default-bold-font-weight);
@@ -12440,10 +12443,11 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12440
12443
  text-transform:var(--body-default-bold-text-case);
12441
12444
  }
12442
12445
 
12443
- .bp_notification_module_root--c9108[data-modern=true]{
12446
+ .bp_notification_module_root--3428d[data-modern=true]{
12444
12447
  --notification-padding-vertical:var(--bp-space-030);
12445
12448
  --notification-padding-horizontal:var(--bp-space-040);
12446
12449
  --notification-item-spacing:var(--bp-space-030);
12450
+ --notification-item-row-spacing:var(--bp-space-040);
12447
12451
  --notification-radius:var(--bp-radius-16);
12448
12452
  --notification-border:var(--bp-border-02);
12449
12453
  --notification-shadow:var(--dropshadow-3);
@@ -12463,7 +12467,7 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12463
12467
  --notification-icon-size:var(--bp-size-080);
12464
12468
  --notification-icon-margin:0.375rem;
12465
12469
  }
12466
- .bp_notification_module_root--c9108[data-modern=true] .bp_notification_module_text--c9108{
12470
+ .bp_notification_module_root--3428d[data-modern=true] .bp_notification_module_text--3428d{
12467
12471
  font-family:var(--bp-font-font-family), -apple-system, BlinkMacSystemFont, "San Francisco", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
12468
12472
  font-size:var(--bp-font-size-05);
12469
12473
  font-style:normal;
@@ -12471,7 +12475,7 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12471
12475
  letter-spacing:var(--bp-font-letter-spacing-01);
12472
12476
  line-height:var(--bp-font-line-height-04);
12473
12477
  }
12474
- :where(body.is-inter-font) .bp_notification_module_root--c9108[data-modern=true] .bp_notification_module_text--c9108{
12478
+ :where(body.is-inter-font) .bp_notification_module_root--3428d[data-modern=true] .bp_notification_module_text--3428d{
12475
12479
  font-family:"Inter Variable", -apple-system, BlinkMacSystemFont, "San Francisco", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
12476
12480
  font-size:.875rem;
12477
12481
  font-style:normal;
@@ -12482,145 +12486,115 @@ div[data-radix-popper-content-wrapper]:has([role=menu]):has([data-state=open]):h
12482
12486
  text-transform:none;
12483
12487
  }
12484
12488
 
12485
- .bp_notification_module_root--c9108[data-modern=true].bp_notification_module_info--c9108{
12489
+ .bp_notification_module_root--3428d[data-modern=true].bp_notification_module_info--3428d{
12486
12490
  background:linear-gradient(0deg, var(--notification-background-info) 0, var(--notification-background-info) 100%), var(--notification-background-overlay);
12487
12491
  }
12488
- .bp_notification_module_root--c9108[data-modern=true].bp_notification_module_success--c9108{
12492
+ .bp_notification_module_root--3428d[data-modern=true].bp_notification_module_success--3428d{
12489
12493
  background:linear-gradient(0deg, var(--notification-background-success) 0, var(--notification-background-success) 100%), var(--notification-background-overlay);
12490
12494
  }
12491
- .bp_notification_module_root--c9108[data-modern=true].bp_notification_module_warning--c9108{
12495
+ .bp_notification_module_root--3428d[data-modern=true].bp_notification_module_warning--3428d{
12492
12496
  background:linear-gradient(0deg, var(--notification-background-warning) 0, var(--notification-background-warning) 100%), var(--notification-background-overlay);
12493
12497
  }
12494
- .bp_notification_module_root--c9108[data-modern=true].bp_notification_module_error--c9108{
12498
+ .bp_notification_module_root--3428d[data-modern=true].bp_notification_module_error--3428d{
12495
12499
  background:linear-gradient(0deg, var(--notification-background-error) 0, var(--notification-background-error) 100%), var(--notification-background-overlay);
12496
12500
  }
12497
12501
 
12498
- .bp_notification_module_root--c9108{
12502
+ .bp_notification_module_root--3428d{
12499
12503
  backdrop-filter:blur(var(--notification-background-blur));
12500
12504
  border:var(--notification-border) solid;
12501
12505
  border-radius:var(--notification-radius);
12502
12506
  box-shadow:var(--notification-shadow);
12507
+ box-sizing:border-box;
12503
12508
  display:flex;
12504
- max-width:288px;
12509
+ max-width:min(var(--notification-width), 100vw - var(--bp-space-040, var(--space-4)) * 2);
12505
12510
  padding:var(--notification-padding-vertical) var(--notification-padding-horizontal);
12506
- width:max-content;
12507
- }
12508
- @media (width > 374px){
12509
- .bp_notification_module_root--c9108{
12510
- max-width:343px;
12511
- }
12511
+ width:min(var(--notification-width), 100vw - var(--bp-space-040, var(--space-4)) * 2);
12512
12512
  }
12513
- @media (width > 767px){
12514
- .bp_notification_module_root--c9108{
12515
- max-width:728px;
12516
- }
12517
- }
12518
- @media (width > 1023px){
12519
- .bp_notification_module_root--c9108{
12520
- max-width:848px;
12521
- }
12522
- }
12523
- @media (width > 1219px){
12524
- .bp_notification_module_root--c9108{
12525
- max-width:896px;
12526
- }
12527
- }
12528
- .bp_notification_module_root--c9108 .bp_notification_module_container--c9108{
12513
+ .bp_notification_module_root--3428d .bp_notification_module_container--3428d{
12529
12514
  align-items:flex-start;
12530
12515
  display:flex;
12531
12516
  gap:var(--notification-item-spacing);
12517
+ min-width:0;
12532
12518
  width:100%;
12533
12519
  }
12534
- @media (width > 767px){
12535
- .bp_notification_module_root--c9108 .bp_notification_module_container--c9108{
12536
- align-items:center;
12537
- }
12538
- }
12539
- .bp_notification_module_root--c9108 .bp_notification_module_mobileContainer--c9108{
12540
- align-items:left;
12520
+ .bp_notification_module_root--3428d .bp_notification_module_messageRow--3428d{
12521
+ align-items:center;
12541
12522
  display:flex;
12542
- flex-direction:column;
12523
+ flex:1 1 auto;
12524
+ flex-wrap:wrap;
12525
+ min-width:0;
12543
12526
  overflow:hidden;
12544
12527
  width:100%;
12545
12528
  }
12546
- @media (width > 767px){
12547
- .bp_notification_module_root--c9108 .bp_notification_module_mobileContainer--c9108{
12548
- align-items:center;
12549
- flex-direction:row;
12550
- }
12529
+ .bp_notification_module_root--3428d .bp_notification_module_withButtons--3428d{
12530
+ gap:var(--notification-item-row-spacing) var(--notification-item-spacing);
12551
12531
  }
12552
- .bp_notification_module_root--c9108 .bp_notification_module_withButtons--c9108{
12553
- gap:var(--notification-item-spacing);
12554
- }
12555
- .bp_notification_module_root--c9108.bp_notification_module_info--c9108{
12532
+ .bp_notification_module_root--3428d.bp_notification_module_info--3428d{
12556
12533
  background:var(--notification-background-info);
12557
12534
  border-color:var(--notification-border-color-info);
12558
12535
  }
12559
- .bp_notification_module_root--c9108.bp_notification_module_success--c9108{
12536
+ .bp_notification_module_root--3428d.bp_notification_module_success--3428d{
12560
12537
  background:var(--notification-background-success);
12561
12538
  border-color:var(--notification-border-color-success);
12562
12539
  }
12563
- .bp_notification_module_root--c9108.bp_notification_module_warning--c9108{
12540
+ .bp_notification_module_root--3428d.bp_notification_module_warning--3428d{
12564
12541
  background:var(--notification-background-warning);
12565
12542
  border-color:var(--notification-border-color-warning);
12566
12543
  }
12567
- .bp_notification_module_root--c9108.bp_notification_module_error--c9108{
12544
+ .bp_notification_module_root--3428d.bp_notification_module_error--3428d{
12568
12545
  background:var(--notification-background-error);
12569
12546
  border-color:var(--notification-border-color-error);
12570
12547
  }
12571
- .bp_notification_module_root--c9108:focus-visible{
12548
+ .bp_notification_module_root--3428d:focus-visible{
12572
12549
  box-shadow:0 0 0 var(--border-1, 1px) var(--background-background), 0 0 0 var(--border-3) var(--notification-outline-focus);
12573
12550
  outline:none;
12574
12551
  }
12575
- .bp_notification_module_root--c9108 .bp_notification_module_typeIconContainer--c9108{
12552
+ .bp_notification_module_root--3428d .bp_notification_module_typeIconContainer--3428d{
12576
12553
  align-items:center;
12577
12554
  display:flex;
12578
12555
  height:var(--notification-icon-size);
12579
12556
  justify-content:center;
12580
12557
  width:var(--notification-icon-size);
12581
12558
  }
12582
- .bp_notification_module_root--c9108 .bp_notification_module_typeIconContainer--c9108 .bp_notification_module_typeIcon--c9108{
12559
+ .bp_notification_module_root--3428d .bp_notification_module_typeIconContainer--3428d .bp_notification_module_typeIcon--3428d{
12583
12560
  flex-shrink:0;
12584
12561
  margin:var(--notification-icon-margin);
12585
12562
  }
12586
- .bp_notification_module_root--c9108 .bp_notification_module_text--c9108{
12563
+ .bp_notification_module_root--3428d .bp_notification_module_text--3428d{
12587
12564
  align-items:center;
12588
12565
  color:var(--notification-text-color);
12589
12566
  display:flex;
12567
+ flex:1 1 auto;
12590
12568
  gap:var(--notification-item-spacing);
12591
12569
  min-height:var(--notification-text-container-height);
12570
+ min-width:0;
12592
12571
  overflow:hidden;
12593
12572
  }
12594
- .bp_notification_module_root--c9108 .bp_notification_module_text--c9108 > div{
12573
+ .bp_notification_module_root--3428d .bp_notification_module_text--3428d > div{
12595
12574
  overflow:hidden;
12596
12575
  overflow-wrap:break-word;
12597
12576
  }
12598
- .bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108{
12577
+ .bp_notification_module_root--3428d .bp_notification_module_contentButtonSection--3428d{
12599
12578
  display:flex;
12579
+ flex:0 0 auto;
12600
12580
  gap:var(--notification-item-spacing);
12601
- margin-left:0;
12602
- }
12603
- @media (width > 767px){
12604
- .bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108{
12605
- margin-left:auto;
12606
- }
12607
12581
  }
12608
- .bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108 .bp_notification_module_contentButtons--c9108{
12582
+ .bp_notification_module_root--3428d .bp_notification_module_contentButtonSection--3428d .bp_notification_module_contentButtons--3428d{
12609
12583
  display:flex;
12610
12584
  gap:var(--notification-item-spacing);
12611
12585
  }
12612
- .bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108 .bp_notification_module_contentButtons--c9108 a,.bp_notification_module_root--c9108 .bp_notification_module_contentButtonSection--c9108 .bp_notification_module_contentButtons--c9108 button{
12586
+ .bp_notification_module_root--3428d .bp_notification_module_contentButtonSection--3428d .bp_notification_module_contentButtons--3428d a,.bp_notification_module_root--3428d .bp_notification_module_contentButtonSection--3428d .bp_notification_module_contentButtons--3428d button{
12613
12587
  cursor:pointer;
12614
12588
  }
12615
- .bp_notification_module_root--c9108 .bp_notification_module_closeButtonSection--c9108{
12589
+ .bp_notification_module_root--3428d .bp_notification_module_closeButtonSection--3428d{
12616
12590
  display:flex;
12617
12591
  gap:var(--notification-item-spacing);
12618
12592
  margin-left:auto;
12619
12593
  }
12620
- .bp_notification_module_root--c9108 .bp_notification_module_closeButtonSection--c9108 .bp_notification_module_closeButton--c9108{
12594
+ .bp_notification_module_root--3428d .bp_notification_module_closeButtonSection--3428d .bp_notification_module_closeButton--3428d{
12621
12595
  align-self:center;
12622
12596
  }
12623
- .bp_notification_module_root--c9108 .bp_notification_module_closeButtonSection--c9108 .bp_notification_module_closeButton--c9108 svg *{
12597
+ .bp_notification_module_root--3428d .bp_notification_module_closeButtonSection--3428d .bp_notification_module_closeButton--3428d svg *{
12624
12598
  fill:currentcolor;
12625
12599
  }
12626
12600
  .bp_popover_module_popoverContentContainer--6fc5b .bp_popover_module_popoverCard--6fc5b .bp_popover_module_popoverMainContent--6fc5b,.bp_popover_module_popoverContentContainer--6fc5b.bp_popover_module_accessibilitySmallBreakpoint--6fc5b .bp_popover_module_popoverCard--6fc5b .bp_popover_module_popoverScrollContainer--6fc5b{
@@ -119,6 +119,7 @@ export { useFullTextTooltip } from './utils/useFullTextTooltip.js';
119
119
  export { useIsEllipsized } from './utils/useIsEllipsized.js';
120
120
  export { getUniqueId, useUniqueId } from './utils/useUniqueId.js';
121
121
  export { VisuallyHidden } from './visually-hidden/visually-hidden.js';
122
+ export { NOTIFICATION_COPY_MAX_LENGTH, truncateNotificationCopy } from './primitives/notification/truncate-notification-copy.js';
122
123
  export { PageGlobalHeaderSearchContainerPortal, PageHeaderEndElementsPortal, PageHeaderStartElementsPortal, PageSidePanelPortal, PageSubNavigationPortal } from './page/page-portal.js';
123
124
  export { useMainSectionSidebar, usePageNavigation, useSidePanel } from './page/page-context.js';
124
125
  export { useNotification } from './primitives/notification/notification-provider.js';
@@ -1,6 +1,7 @@
1
1
  export { type NotificationButtonProps } from './notification-button';
2
2
  export { useNotification, type NotificationProviderProps } from './notification-provider';
3
3
  export { type NotificationViewportProps } from './notification.viewport';
4
+ export { NOTIFICATION_COPY_MAX_LENGTH, truncateNotificationCopy } from './truncate-notification-copy';
4
5
  export declare const Notification: {
5
6
  Provider: import("react").FC<import("react").PropsWithChildren<import("@radix-ui/react-toast").ToastProviderProps>>;
6
7
  Button: {
@@ -4,6 +4,7 @@ import * as React from 'react';
4
4
  import { useState, useContext } from 'react';
5
5
  import { deepMerge } from '../../utils/deepMerge.js';
6
6
  import { getUniqueId } from '../../utils/useUniqueId.js';
7
+ import { truncateNotificationCopy } from './truncate-notification-copy.js';
7
8
 
8
9
  const DEFAULT_NOTIFICATION_DELAY = 5000;
9
10
  const NotificationContext = /*#__PURE__*/React.createContext(null);
@@ -52,7 +53,7 @@ const NotificationProvider = props => {
52
53
  closeButtonAriaLabel,
53
54
  onClose: onClose(notificationId),
54
55
  sensitivity,
55
- styledText,
56
+ styledText: truncateNotificationCopy(styledText),
56
57
  typeIconAriaLabel,
57
58
  variant
58
59
  };
@@ -77,8 +78,12 @@ const NotificationProvider = props => {
77
78
  if (oldNotificationProps === undefined) {
78
79
  return oldValue;
79
80
  }
81
+ const nextProps = newProps.styledText === undefined ? newProps : {
82
+ ...newProps,
83
+ styledText: truncateNotificationCopy(newProps.styledText)
84
+ };
80
85
  const newNotifications = new Map(oldValue);
81
- newNotifications.set(id, deepMerge(oldNotificationProps, newProps));
86
+ newNotifications.set(id, deepMerge(oldNotificationProps, nextProps));
82
87
  return newNotifications;
83
88
  });
84
89
  }, []);
@@ -1,4 +1,4 @@
1
1
  import '../../index.css';
2
- var styles = {"viewport":"bp_notification_module_viewport--c9108","root":"bp_notification_module_root--c9108","text":"bp_notification_module_text--c9108","info":"bp_notification_module_info--c9108","success":"bp_notification_module_success--c9108","warning":"bp_notification_module_warning--c9108","error":"bp_notification_module_error--c9108","container":"bp_notification_module_container--c9108","mobileContainer":"bp_notification_module_mobileContainer--c9108","withButtons":"bp_notification_module_withButtons--c9108","typeIconContainer":"bp_notification_module_typeIconContainer--c9108","typeIcon":"bp_notification_module_typeIcon--c9108","contentButtonSection":"bp_notification_module_contentButtonSection--c9108","contentButtons":"bp_notification_module_contentButtons--c9108","closeButtonSection":"bp_notification_module_closeButtonSection--c9108","closeButton":"bp_notification_module_closeButton--c9108"};
2
+ var styles = {"viewport":"bp_notification_module_viewport--3428d","root":"bp_notification_module_root--3428d","text":"bp_notification_module_text--3428d","info":"bp_notification_module_info--3428d","success":"bp_notification_module_success--3428d","warning":"bp_notification_module_warning--3428d","error":"bp_notification_module_error--3428d","container":"bp_notification_module_container--3428d","messageRow":"bp_notification_module_messageRow--3428d","withButtons":"bp_notification_module_withButtons--3428d","typeIconContainer":"bp_notification_module_typeIconContainer--3428d","typeIcon":"bp_notification_module_typeIcon--3428d","contentButtonSection":"bp_notification_module_contentButtonSection--3428d","contentButtons":"bp_notification_module_contentButtons--3428d","closeButtonSection":"bp_notification_module_closeButtonSection--3428d","closeButton":"bp_notification_module_closeButton--3428d"};
3
3
 
4
4
  export { styles as default };
@@ -14,7 +14,11 @@ export interface PrivateNotificationElementProps extends ToastProps {
14
14
  typeIconAriaLabel: string;
15
15
  /** Aria label for the close button */
16
16
  closeButtonAriaLabel: string;
17
- /** The main text of the notification. */
17
+ /**
18
+ * The main text of the notification.
19
+ * String copy is limited to 280 characters (`NOTIFICATION_COPY_MAX_LENGTH`); longer strings are truncated.
20
+ * React-node copy is not character-counted.
21
+ */
18
22
  styledText: StyledText;
19
23
  /** What to do on close. This is provided by addNotification by default */
20
24
  onClose?: () => void;
@@ -8,6 +8,7 @@ import clsx from 'clsx';
8
8
  import { useMemo } from 'react';
9
9
  import { IconButton } from '../icon-button/icon-button.js';
10
10
  import styles from './notification.module.js';
11
+ import { truncateNotificationCopy } from './truncate-notification-copy.js';
11
12
 
12
13
  const createIconProps = iconLabel => ({
13
14
  className: styles.typeIcon,
@@ -73,13 +74,13 @@ function PrivateNotificationElement(props) {
73
74
  className: styles.typeIconContainer,
74
75
  children: iconComponent
75
76
  }), jsxs("div", {
76
- className: clsx(styles.mobileContainer, {
77
+ className: clsx(styles.messageRow, {
77
78
  [styles.withButtons]: children
78
79
  }),
79
80
  children: [jsx("div", {
80
81
  className: styles.text,
81
82
  children: jsx(Toast.Description, {
82
- children: styledText
83
+ children: truncateNotificationCopy(styledText)
83
84
  })
84
85
  }), jsx("div", {
85
86
  className: styles.contentButtonSection,
@@ -0,0 +1,8 @@
1
+ import { type StyledText } from '../../utils/commonTypes';
2
+ /** Maximum character length for string `styledText` on a notification. */
3
+ export declare const NOTIFICATION_COPY_MAX_LENGTH = 280;
4
+ /**
5
+ * Truncates string notification copy to {@link NOTIFICATION_COPY_MAX_LENGTH}.
6
+ * Non-string `styledText` (React nodes) is returned unchanged — this does not walk children.
7
+ */
8
+ export declare const truncateNotificationCopy: (copy: StyledText) => StyledText;
@@ -0,0 +1,14 @@
1
+ /** Maximum character length for string `styledText` on a notification. */
2
+ const NOTIFICATION_COPY_MAX_LENGTH = 280;
3
+ /**
4
+ * Truncates string notification copy to {@link NOTIFICATION_COPY_MAX_LENGTH}.
5
+ * Non-string `styledText` (React nodes) is returned unchanged — this does not walk children.
6
+ */
7
+ const truncateNotificationCopy = copy => {
8
+ if (typeof copy !== 'string' || copy.length <= NOTIFICATION_COPY_MAX_LENGTH) {
9
+ return copy;
10
+ }
11
+ return copy.slice(0, NOTIFICATION_COPY_MAX_LENGTH);
12
+ };
13
+
14
+ export { NOTIFICATION_COPY_MAX_LENGTH, truncateNotificationCopy };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@box/blueprint-web",
3
- "version": "17.11.3",
3
+ "version": "17.11.5",
4
4
  "type": "module",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "publishConfig": {
@@ -55,7 +55,7 @@
55
55
  "dependencies": {
56
56
  "@ariakit/react": "0.4.21",
57
57
  "@ariakit/react-core": "0.4.21",
58
- "@box/blueprint-web-assets": "^5.10.10",
58
+ "@box/blueprint-web-assets": "^5.10.12",
59
59
  "@internationalized/date": "^3.12.0",
60
60
  "@radix-ui/react-accordion": "1.1.2",
61
61
  "@radix-ui/react-checkbox": "1.0.4",
@@ -86,7 +86,7 @@
86
86
  "devDependencies": {
87
87
  "@box/box-test-client": "^3.2.7",
88
88
  "@box/playwright-utils": "^2.8.5",
89
- "@box/storybook-utils": "^1.2.54",
89
+ "@box/storybook-utils": "^1.2.56",
90
90
  "@figma/code-connect": "1.4.4",
91
91
  "@playwright/test": "1.46.1",
92
92
  "@types/js-yaml": "^4.0.9",