openproject-primer_view_components 0.33.1 → 0.33.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/app/assets/styles/primer_view_components.css +1 -1
- data/app/assets/styles/primer_view_components.css.map +1 -1
- data/app/components/primer/beta/breadcrumbs.css +1 -1
- data/app/components/primer/beta/breadcrumbs.css.map +1 -1
- data/app/components/primer/beta/breadcrumbs.pcss +0 -1
- data/lib/primer/view_components/version.rb +1 -1
- data/previews/primer/alpha/banner_preview.rb +1 -1
- data/previews/primer/beta/breadcrumbs_preview/with_beta_truncate.html.erb +15 -0
- data/previews/primer/beta/breadcrumbs_preview/with_deprecated_truncate.html.erb +14 -0
- data/previews/primer/beta/breadcrumbs_preview.rb +12 -0
- data/static/info_arch.json +26 -0
- data/static/previews.json +26 -0
- metadata +4 -2
@@ -1 +1 @@
|
|
1
|
-
.breadcrumb-item{display:inline-block;list-style:none;margin-left:-.35em
|
1
|
+
.breadcrumb-item{display:inline-block;list-style:none;margin-left:-.35em}.breadcrumb-item:after{border-right:.1em solid var(--borderColor-neutral-emphasis);content:"";display:inline-block;height:.8em;margin:0 .5em;transform:rotate(15deg) translateY(.0625em)}.breadcrumb-item:first-child{margin-left:0}.breadcrumb-item-selected:after,.breadcrumb-item[aria-current]:not([aria-current=false]):after{content:none}.breadcrumb-item-selected a{color:var(--fgColor-default);cursor:default!important;-webkit-text-decoration:none!important;text-decoration:none!important}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["breadcrumbs.pcss"],"names":[],"mappings":"AAAA,iBACE,oBAAqB,
|
1
|
+
{"version":3,"sources":["breadcrumbs.pcss"],"names":[],"mappings":"AAAA,iBACE,oBAAqB,CAErB,eAAgB,CADhB,kBAeF,CAZE,uBAKE,2DAA6D,CAD7D,UAAW,CAHX,oBAAqB,CACrB,WAAa,CACb,aAAe,CAGf,2CACF,CAEA,6BACE,aACF,CAKA,+FACE,YACF,CAGF,4BACE,4BAA6B,CAC7B,wBAA0B,CAC1B,sCAAgC,CAAhC,8BACF","file":"breadcrumbs.css","sourcesContent":[".breadcrumb-item {\n display: inline-block;\n margin-left: -0.35em;\n list-style: none;\n\n &::after {\n display: inline-block;\n height: 0.8em;\n margin: 0 0.5em;\n content: '';\n border-right: 0.1em solid var(--borderColor-neutral-emphasis);\n transform: rotate(15deg) translateY(0.0625em);\n }\n\n &:first-child {\n margin-left: 0;\n }\n}\n\n.breadcrumb-item-selected,\n.breadcrumb-item[aria-current]:not([aria-current='false']) {\n &::after {\n content: none;\n }\n}\n\n.breadcrumb-item-selected a {\n color: var(--fgColor-default);\n cursor: default !important;\n text-decoration: none !important;\n}\n"]}
|
@@ -55,7 +55,7 @@ module Primer
|
|
55
55
|
# @label Dismissable
|
56
56
|
# @snapshot
|
57
57
|
def dismissible
|
58
|
-
render(Primer::Alpha::Banner.new(dismiss_scheme: :hide
|
58
|
+
render(Primer::Alpha::Banner.new(dismiss_scheme: :hide)) { "This is a dismissable banner." }
|
59
59
|
end
|
60
60
|
|
61
61
|
# @!group Full Width
|
@@ -0,0 +1,15 @@
|
|
1
|
+
<% texts = [
|
2
|
+
"Breadcrumb Item 1",
|
3
|
+
"Breadcrumb Item 2 with a really long, long, long name",
|
4
|
+
"Breadcrumb Item 3 with an extremely long, long, long name"
|
5
|
+
] %>
|
6
|
+
|
7
|
+
<%= render(Primer::Beta::Breadcrumbs.new) do |breadcrumbs| %>
|
8
|
+
<% texts.each_with_index do |text, i| %>
|
9
|
+
<% breadcrumbs.with_item(href: "##{i}") do %>
|
10
|
+
<%= render(Primer::Beta::Truncate.new) do |truncate| %>
|
11
|
+
<% truncate.with_item(max_width: 135) { text } %>
|
12
|
+
<% end %>
|
13
|
+
<% end %>
|
14
|
+
<% end %>
|
15
|
+
<% end %>
|
@@ -0,0 +1,14 @@
|
|
1
|
+
<%# erblint:counter DeprecatedComponentsCounter 1 %>
|
2
|
+
<% texts = [
|
3
|
+
"Breadcrumb Item 1",
|
4
|
+
"Breadcrumb Item 2 with a really long, long, long name",
|
5
|
+
"Breadcrumb Item 3 with an extremely long, long, long name"
|
6
|
+
] %>
|
7
|
+
|
8
|
+
<%= render(Primer::Beta::Breadcrumbs.new) do |breadcrumbs| %>
|
9
|
+
<% texts.each_with_index do |text, i| %>
|
10
|
+
<% breadcrumbs.with_item(href: "##{i}") do %>
|
11
|
+
<%= render(Primer::Truncate.new(inline: true, max_width: 135)) { text } %>
|
12
|
+
<% end %>
|
13
|
+
<% end %>
|
14
|
+
<% end %>
|
@@ -26,6 +26,18 @@ module Primer
|
|
26
26
|
end
|
27
27
|
end
|
28
28
|
end
|
29
|
+
|
30
|
+
# @label WithBetaTruncate
|
31
|
+
# @snapshot
|
32
|
+
def with_beta_truncate
|
33
|
+
render_with_template
|
34
|
+
end
|
35
|
+
|
36
|
+
# @label WithDeprecatedTruncate
|
37
|
+
# @snapshot
|
38
|
+
def with_deprecated_truncate
|
39
|
+
render_with_template
|
40
|
+
end
|
29
41
|
end
|
30
42
|
end
|
31
43
|
end
|
data/static/info_arch.json
CHANGED
@@ -10921,6 +10921,32 @@
|
|
10921
10921
|
"color-contrast"
|
10922
10922
|
]
|
10923
10923
|
}
|
10924
|
+
},
|
10925
|
+
{
|
10926
|
+
"preview_path": "primer/beta/breadcrumbs/with_beta_truncate",
|
10927
|
+
"name": "with_beta_truncate",
|
10928
|
+
"snapshot": "true",
|
10929
|
+
"skip_rules": {
|
10930
|
+
"wont_fix": [
|
10931
|
+
"region"
|
10932
|
+
],
|
10933
|
+
"will_fix": [
|
10934
|
+
"color-contrast"
|
10935
|
+
]
|
10936
|
+
}
|
10937
|
+
},
|
10938
|
+
{
|
10939
|
+
"preview_path": "primer/beta/breadcrumbs/with_deprecated_truncate",
|
10940
|
+
"name": "with_deprecated_truncate",
|
10941
|
+
"snapshot": "true",
|
10942
|
+
"skip_rules": {
|
10943
|
+
"wont_fix": [
|
10944
|
+
"region"
|
10945
|
+
],
|
10946
|
+
"will_fix": [
|
10947
|
+
"color-contrast"
|
10948
|
+
]
|
10949
|
+
}
|
10924
10950
|
}
|
10925
10951
|
],
|
10926
10952
|
"subcomponents": [
|
data/static/previews.json
CHANGED
@@ -2058,6 +2058,32 @@
|
|
2058
2058
|
"color-contrast"
|
2059
2059
|
]
|
2060
2060
|
}
|
2061
|
+
},
|
2062
|
+
{
|
2063
|
+
"preview_path": "primer/beta/breadcrumbs/with_beta_truncate",
|
2064
|
+
"name": "with_beta_truncate",
|
2065
|
+
"snapshot": "true",
|
2066
|
+
"skip_rules": {
|
2067
|
+
"wont_fix": [
|
2068
|
+
"region"
|
2069
|
+
],
|
2070
|
+
"will_fix": [
|
2071
|
+
"color-contrast"
|
2072
|
+
]
|
2073
|
+
}
|
2074
|
+
},
|
2075
|
+
{
|
2076
|
+
"preview_path": "primer/beta/breadcrumbs/with_deprecated_truncate",
|
2077
|
+
"name": "with_deprecated_truncate",
|
2078
|
+
"snapshot": "true",
|
2079
|
+
"skip_rules": {
|
2080
|
+
"wont_fix": [
|
2081
|
+
"region"
|
2082
|
+
],
|
2083
|
+
"will_fix": [
|
2084
|
+
"color-contrast"
|
2085
|
+
]
|
2086
|
+
}
|
2061
2087
|
}
|
2062
2088
|
]
|
2063
2089
|
},
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: openproject-primer_view_components
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.33.
|
4
|
+
version: 0.33.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GitHub Open Source
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2024-06-
|
12
|
+
date: 2024-06-07 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: actionview
|
@@ -867,6 +867,8 @@ files:
|
|
867
867
|
- previews/primer/beta/blankslate_preview/inside_flex_container.html.erb
|
868
868
|
- previews/primer/beta/border_box_preview.rb
|
869
869
|
- previews/primer/beta/breadcrumbs_preview.rb
|
870
|
+
- previews/primer/beta/breadcrumbs_preview/with_beta_truncate.html.erb
|
871
|
+
- previews/primer/beta/breadcrumbs_preview/with_deprecated_truncate.html.erb
|
870
872
|
- previews/primer/beta/button_group_preview.rb
|
871
873
|
- previews/primer/beta/button_group_preview/with_menu_button.html.erb
|
872
874
|
- previews/primer/beta/button_preview.rb
|