playbook_ui 14.13.0.pre.rc.10 → 14.13.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/pb_kits/playbook/pb_advanced_table/_advanced_table.scss +63 -1
- data/app/pb_kits/playbook/pb_advanced_table/_advanced_table.tsx +3 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props.jsx +1 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props_react.md +3 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props_sticky_header.jsx +55 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_props_sticky_header_react.md +3 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/example.yml +1 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/index.js +2 -1
- data/app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers_rails.html.erb +99 -0
- data/app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers_rails.md +1 -0
- data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table.html.erb +61 -0
- data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table.md +1 -0
- data/app/pb_kits/playbook/pb_draggable/docs/example.yml +2 -5
- data/app/pb_kits/playbook/pb_draggable/draggable_container.html.erb +2 -2
- data/app/pb_kits/playbook/pb_draggable/draggable_container.rb +5 -0
- data/app/pb_kits/playbook/pb_draggable/draggable_item.html.erb +1 -1
- data/app/pb_kits/playbook/pb_draggable/draggable_item.rb +4 -0
- data/app/pb_kits/playbook/pb_draggable/index.js +151 -15
- data/app/pb_kits/playbook/pb_home_address_street/_home_address_street.tsx +11 -7
- data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_formatting.html.erb +11 -0
- data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_formatting.jsx +22 -0
- data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_formatting_rails.md +1 -0
- data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_formatting_react.md +1 -0
- data/app/pb_kits/playbook/pb_home_address_street/docs/example.yml +2 -0
- data/app/pb_kits/playbook/pb_home_address_street/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_home_address_street/home_address_street.rb +13 -2
- data/app/pb_kits/playbook/pb_icon/icon.html.erb +2 -6
- data/app/pb_kits/playbook/pb_layout/body.html.erb +1 -5
- data/app/pb_kits/playbook/pb_layout/footer.html.erb +1 -5
- data/app/pb_kits/playbook/pb_layout/header.html.erb +1 -5
- data/app/pb_kits/playbook/pb_layout/item.html.erb +1 -5
- data/app/pb_kits/playbook/pb_layout/layout.html.erb +1 -5
- data/app/pb_kits/playbook/pb_layout/sidebar.html.erb +1 -5
- data/app/pb_kits/playbook/pb_legend/legend.html.erb +1 -6
- data/app/pb_kits/playbook/pb_message/message.html.erb +1 -6
- data/app/pb_kits/playbook/pb_message/message_mention.html.erb +1 -6
- data/app/pb_kits/playbook/pb_text_input/docs/_text_input_mask.html.erb +1 -1
- data/app/pb_kits/playbook/pb_text_input/index.js +52 -83
- data/dist/chunks/{_typeahead-CkemExmL.js → _typeahead-btjo1UN5.js} +2 -2
- data/dist/chunks/_weekday_stacked-DeYS_l8v.js +45 -0
- data/dist/chunks/lazysizes-DHz07jlL.js +1 -0
- data/dist/chunks/vendor.js +1 -1
- data/dist/playbook-doc.js +1 -1
- data/dist/playbook-rails-react-bindings.js +1 -1
- data/dist/playbook-rails.js +1 -1
- data/dist/playbook.css +1 -1
- data/lib/playbook/version.rb +1 -1
- metadata +15 -5
- data/dist/chunks/_weekday_stacked-CtSzPEH0.js +0 -45
- data/dist/chunks/lazysizes-B7xYodB-.js +0 -1
@@ -9,12 +9,38 @@ export default class PbDraggable extends PbEnhancedElement {
|
|
9
9
|
}
|
10
10
|
|
11
11
|
connect() {
|
12
|
+
this.state = {
|
13
|
+
items: [],
|
14
|
+
dragData: { id: "", initialGroup: "" },
|
15
|
+
isDragging: "",
|
16
|
+
activeContainer: ""
|
17
|
+
};
|
18
|
+
|
12
19
|
this.draggedItem = null;
|
13
20
|
this.draggedItemId = null;
|
21
|
+
this.hasMultipleContainers = false;
|
22
|
+
|
14
23
|
document.addEventListener("DOMContentLoaded", () => this.bindEventListeners());
|
15
24
|
}
|
16
25
|
|
26
|
+
setState(newState) {
|
27
|
+
this.state = { ...this.state, ...newState };
|
28
|
+
if (newState.items) {
|
29
|
+
const customEvent = new CustomEvent('pb-draggable-reorder', {
|
30
|
+
detail: {
|
31
|
+
reorderedItems: this.state.items,
|
32
|
+
containerId: this.element.querySelector(DRAGGABLE_CONTAINER).id
|
33
|
+
}
|
34
|
+
});
|
35
|
+
this.element.dispatchEvent(customEvent);
|
36
|
+
}
|
37
|
+
}
|
38
|
+
|
17
39
|
bindEventListeners() {
|
40
|
+
// Check for multiple containers
|
41
|
+
const containers = this.element.querySelectorAll(DRAGGABLE_CONTAINER);
|
42
|
+
this.hasMultipleContainers = containers.length > 1;
|
43
|
+
|
18
44
|
// Needed to prevent images within draggable items from being independently draggable
|
19
45
|
// Needed if using Image kit in draggable items
|
20
46
|
this.element.querySelectorAll(".pb_draggable_item img").forEach(img => {
|
@@ -27,11 +53,10 @@ export default class PbDraggable extends PbEnhancedElement {
|
|
27
53
|
item.addEventListener("dragenter", this.handleDragEnter.bind(this));
|
28
54
|
});
|
29
55
|
|
30
|
-
|
31
|
-
if (container) {
|
56
|
+
containers.forEach(container => {
|
32
57
|
container.addEventListener("dragover", this.handleDragOver.bind(this));
|
33
58
|
container.addEventListener("drop", this.handleDrop.bind(this));
|
34
|
-
}
|
59
|
+
});
|
35
60
|
}
|
36
61
|
|
37
62
|
handleDragStart(event) {
|
@@ -41,11 +66,17 @@ export default class PbDraggable extends PbEnhancedElement {
|
|
41
66
|
event.preventDefault();
|
42
67
|
return;
|
43
68
|
}
|
44
|
-
|
69
|
+
|
70
|
+
const container = event.target.closest(DRAGGABLE_CONTAINER);
|
45
71
|
this.draggedItem = event.target;
|
46
72
|
this.draggedItemId = event.target.id;
|
47
|
-
event.target.classList.add("is_dragging");
|
48
73
|
|
74
|
+
this.setState({
|
75
|
+
dragData: { id: this.draggedItemId, initialGroup: container.id },
|
76
|
+
isDragging: this.draggedItemId
|
77
|
+
});
|
78
|
+
|
79
|
+
event.target.classList.add("is_dragging");
|
49
80
|
if (event.dataTransfer) {
|
50
81
|
event.dataTransfer.effectAllowed = 'move';
|
51
82
|
event.dataTransfer.setData('text/plain', this.draggedItemId);
|
@@ -59,11 +90,20 @@ export default class PbDraggable extends PbEnhancedElement {
|
|
59
90
|
handleDragEnter(event) {
|
60
91
|
if (!this.draggedItem || event.target === this.draggedItem) return;
|
61
92
|
|
93
|
+
if (this.hasMultipleContainers) {
|
94
|
+
this.handleMultiContainerDragEnter(event);
|
95
|
+
} else {
|
96
|
+
this.handleSingleContainerDragEnter(event);
|
97
|
+
}
|
98
|
+
}
|
99
|
+
|
100
|
+
handleSingleContainerDragEnter(event) {
|
62
101
|
const targetItem = event.target.closest('.pb_draggable_item');
|
63
102
|
if (!targetItem) return;
|
64
103
|
|
65
104
|
const container = targetItem.parentNode;
|
66
105
|
const items = Array.from(container.children);
|
106
|
+
|
67
107
|
const draggedIndex = items.indexOf(this.draggedItem);
|
68
108
|
const targetIndex = items.indexOf(targetItem);
|
69
109
|
|
@@ -74,47 +114,143 @@ export default class PbDraggable extends PbEnhancedElement {
|
|
74
114
|
}
|
75
115
|
}
|
76
116
|
|
117
|
+
handleMultiContainerDragEnter(event) {
|
118
|
+
const targetContainer = event.target.closest(DRAGGABLE_CONTAINER);
|
119
|
+
const targetItem = event.target.closest('.pb_draggable_item');
|
120
|
+
|
121
|
+
if (!targetContainer) return;
|
122
|
+
|
123
|
+
// If we're entering a container directly or there's no target item
|
124
|
+
if (!targetItem) {
|
125
|
+
const lastItem = targetContainer.querySelector('.pb_draggable_item:last-child');
|
126
|
+
if (lastItem) {
|
127
|
+
targetContainer.insertBefore(this.draggedItem, lastItem.nextSibling);
|
128
|
+
} else {
|
129
|
+
targetContainer.appendChild(this.draggedItem);
|
130
|
+
}
|
131
|
+
return;
|
132
|
+
}
|
133
|
+
|
134
|
+
const container = targetItem.parentNode;
|
135
|
+
const items = Array.from(container.children);
|
136
|
+
|
137
|
+
const newItems = [...items].map(item => ({
|
138
|
+
id: item.id,
|
139
|
+
container: container.id
|
140
|
+
}));
|
141
|
+
|
142
|
+
this.setState({ items: newItems });
|
143
|
+
|
144
|
+
const rect = targetItem.getBoundingClientRect();
|
145
|
+
const middleY = rect.top + rect.height / 2;
|
146
|
+
|
147
|
+
if (event.clientY < middleY) {
|
148
|
+
container.insertBefore(this.draggedItem, targetItem);
|
149
|
+
} else {
|
150
|
+
container.insertBefore(this.draggedItem, targetItem.nextSibling);
|
151
|
+
}
|
152
|
+
}
|
153
|
+
|
77
154
|
handleDragOver(event) {
|
78
155
|
event.preventDefault();
|
156
|
+
event.stopPropagation();
|
157
|
+
|
158
|
+
if (this.hasMultipleContainers) {
|
159
|
+
this.handleMultiContainerDragOver(event);
|
160
|
+
} else {
|
161
|
+
this.handleSingleContainerDragOver(event);
|
162
|
+
}
|
163
|
+
}
|
164
|
+
|
165
|
+
handleSingleContainerDragOver(event) {
|
79
166
|
const container = event.target.closest(DRAGGABLE_CONTAINER);
|
167
|
+
if (container) {
|
168
|
+
container.classList.add("active_container");
|
169
|
+
}
|
170
|
+
}
|
171
|
+
|
172
|
+
handleMultiContainerDragOver(event) {
|
173
|
+
let container;
|
174
|
+
if (event.target.matches(DRAGGABLE_CONTAINER)) {
|
175
|
+
container = event.target;
|
176
|
+
} else {
|
177
|
+
container = event.target.closest(DRAGGABLE_CONTAINER);
|
178
|
+
}
|
80
179
|
|
81
180
|
if (container) {
|
181
|
+
this.setState({ activeContainer: container.id });
|
82
182
|
container.classList.add("active_container");
|
183
|
+
|
184
|
+
// If dragging over empty container or below last item
|
185
|
+
const lastItem = container.querySelector('.pb_draggable_item:last-child');
|
186
|
+
if (!lastItem || (lastItem && event.clientY > lastItem.getBoundingClientRect().bottom)) {
|
187
|
+
if (this.draggedItem && this.draggedItem.parentNode !== container) {
|
188
|
+
container.appendChild(this.draggedItem);
|
189
|
+
}
|
190
|
+
}
|
83
191
|
}
|
84
192
|
}
|
85
193
|
|
86
194
|
handleDrop(event) {
|
87
195
|
event.preventDefault();
|
88
|
-
|
196
|
+
event.stopPropagation();
|
197
|
+
|
198
|
+
let container;
|
199
|
+
if (event.target.matches(DRAGGABLE_CONTAINER)) {
|
200
|
+
container = event.target;
|
201
|
+
} else {
|
202
|
+
container = event.target.closest(DRAGGABLE_CONTAINER);
|
203
|
+
}
|
204
|
+
|
89
205
|
if (!container || !this.draggedItem) return;
|
90
|
-
|
206
|
+
|
91
207
|
container.classList.remove("active_container");
|
92
208
|
this.draggedItem.style.opacity = '1';
|
93
|
-
|
209
|
+
|
210
|
+
// Handle empty containers
|
211
|
+
if (this.hasMultipleContainers && !container.querySelector('.pb_draggable_item')) {
|
212
|
+
container.appendChild(this.draggedItem);
|
213
|
+
}
|
214
|
+
|
94
215
|
// Updated order of items as an array of item IDs
|
95
|
-
const reorderedItems = Array.from(
|
96
|
-
.
|
97
|
-
|
98
|
-
|
216
|
+
const reorderedItems = Array.from(
|
217
|
+
this.element.querySelectorAll('.pb_draggable_item')
|
218
|
+
).map(item => ({
|
219
|
+
id: item.id,
|
220
|
+
container: item.closest(DRAGGABLE_CONTAINER).id
|
221
|
+
}));
|
222
|
+
|
99
223
|
// Store reordered items in a data attribute on the container
|
100
224
|
container.setAttribute("data-reordered-items", JSON.stringify(reorderedItems));
|
101
|
-
|
225
|
+
|
102
226
|
const customEvent = new CustomEvent('pb-draggable-reorder', {
|
103
227
|
detail: {
|
104
228
|
reorderedItems,
|
105
229
|
containerId: container.id,
|
106
230
|
}
|
107
231
|
});
|
232
|
+
|
108
233
|
this.element.dispatchEvent(customEvent);
|
109
|
-
|
234
|
+
|
235
|
+
this.setState({
|
236
|
+
items: reorderedItems,
|
237
|
+
isDragging: "",
|
238
|
+
activeContainer: ""
|
239
|
+
});
|
240
|
+
|
110
241
|
this.draggedItem = null;
|
111
242
|
this.draggedItemId = null;
|
112
243
|
}
|
113
|
-
|
114
244
|
|
115
245
|
handleDragEnd(event) {
|
116
246
|
event.target.classList.remove("is_dragging");
|
117
247
|
event.target.style.opacity = '1';
|
248
|
+
|
249
|
+
this.setState({
|
250
|
+
isDragging: "",
|
251
|
+
activeContainer: ""
|
252
|
+
});
|
253
|
+
|
118
254
|
this.draggedItem = null;
|
119
255
|
this.draggedItemId = null;
|
120
256
|
|
@@ -18,6 +18,7 @@ type HomeAddressStreetProps = {
|
|
18
18
|
className?: string,
|
19
19
|
data?: { [key: string]: string },
|
20
20
|
dark?: boolean,
|
21
|
+
preserveCase?: boolean,
|
21
22
|
emphasis: "street" | "city" | "none",
|
22
23
|
htmlOptions?: {[key: string]: string | number | boolean | (() => void)},
|
23
24
|
homeId: string,
|
@@ -43,6 +44,7 @@ const HomeAddressStreet = (props: HomeAddressStreetProps): React.ReactElement =>
|
|
43
44
|
htmlOptions = {},
|
44
45
|
homeId,
|
45
46
|
homeUrl,
|
47
|
+
preserveCase = false,
|
46
48
|
target,
|
47
49
|
newWindow,
|
48
50
|
houseStyle,
|
@@ -77,6 +79,8 @@ const HomeAddressStreet = (props: HomeAddressStreetProps): React.ReactElement =>
|
|
77
79
|
return null
|
78
80
|
}
|
79
81
|
|
82
|
+
const formatStreetAdr = (address: string): string => preserveCase ? address : titleize(address)
|
83
|
+
|
80
84
|
return (
|
81
85
|
<div
|
82
86
|
className={classes(className, dark)}
|
@@ -91,7 +95,7 @@ const HomeAddressStreet = (props: HomeAddressStreetProps): React.ReactElement =>
|
|
91
95
|
dark={dark}
|
92
96
|
size={4}
|
93
97
|
>
|
94
|
-
{joinPresent([
|
98
|
+
{joinPresent([formatStreetAdr(address), houseStyle], ' · ')}
|
95
99
|
</Title>
|
96
100
|
<Title
|
97
101
|
className="pb_home_address_street_address"
|
@@ -101,14 +105,14 @@ const HomeAddressStreet = (props: HomeAddressStreetProps): React.ReactElement =>
|
|
101
105
|
{titleize(addressCont)}
|
102
106
|
</Title>
|
103
107
|
<Body color="light">
|
104
|
-
{`${titleize(city)}, ${state} ${zipcode}`}
|
108
|
+
{`${titleize(city)}, ${state.toUpperCase()} ${zipcode}`}
|
105
109
|
</Body>
|
106
110
|
</div>
|
107
111
|
}
|
108
112
|
{emphasis == 'city' &&
|
109
113
|
<div>
|
110
114
|
<Body color="light">
|
111
|
-
{joinPresent([
|
115
|
+
{joinPresent([formatStreetAdr(address), houseStyle], ' · ')}
|
112
116
|
</Body>
|
113
117
|
<Body color="light">{titleize(addressCont)}</Body>
|
114
118
|
<div>
|
@@ -118,7 +122,7 @@ const HomeAddressStreet = (props: HomeAddressStreetProps): React.ReactElement =>
|
|
118
122
|
size={4}
|
119
123
|
tag="span"
|
120
124
|
>
|
121
|
-
{`${titleize(city)}, ${state}`}
|
125
|
+
{`${titleize(city)}, ${state.toUpperCase()}`}
|
122
126
|
</Title>
|
123
127
|
<Body
|
124
128
|
color="light"
|
@@ -132,15 +136,15 @@ const HomeAddressStreet = (props: HomeAddressStreetProps): React.ReactElement =>
|
|
132
136
|
{emphasis == 'none' &&
|
133
137
|
<div>
|
134
138
|
<Body dark={dark}>
|
135
|
-
{joinPresent([
|
139
|
+
{joinPresent([formatStreetAdr(address), houseStyle], ' · ')}
|
136
140
|
</Body>
|
137
|
-
<Body dark={dark}>{
|
141
|
+
<Body dark={dark}>{formatStreetAdr(addressCont)}</Body>
|
138
142
|
<div>
|
139
143
|
<Body
|
140
144
|
color="light"
|
141
145
|
dark={dark}
|
142
146
|
>
|
143
|
-
{`${titleize(city)}, ${state} ${zipcode}`}
|
147
|
+
{`${titleize(city)}, ${state.toUpperCase()} ${zipcode}`}
|
144
148
|
</Body>
|
145
149
|
</div>
|
146
150
|
</div>
|
data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_formatting.html.erb
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
<%= pb_rails("home_address_street", props: {
|
2
|
+
address: "70 pRoSpEcT ave",
|
3
|
+
address_cont: "Apt M18",
|
4
|
+
city: "West Chester",
|
5
|
+
home_id: 8250263,
|
6
|
+
home_url: "https://powerhrg.com/",
|
7
|
+
preserve_case: true,
|
8
|
+
state: "pa",
|
9
|
+
zipcode: "19382",
|
10
|
+
territory: "PHL",
|
11
|
+
}) %>
|
@@ -0,0 +1,22 @@
|
|
1
|
+
import React from 'react'
|
2
|
+
|
3
|
+
import HomeAddressStreet from '../_home_address_street'
|
4
|
+
|
5
|
+
const HomeAddressStreetFormatting = (props) => {
|
6
|
+
return (
|
7
|
+
<HomeAddressStreet
|
8
|
+
address="70 pRoSpEcT ave"
|
9
|
+
addressCont="Apt M18"
|
10
|
+
city="West Chester"
|
11
|
+
homeId="8250263"
|
12
|
+
homeUrl="https://powerhrg.com/"
|
13
|
+
preserveCase
|
14
|
+
state="pa"
|
15
|
+
territory="PHL"
|
16
|
+
zipcode="19382"
|
17
|
+
{...props}
|
18
|
+
/>
|
19
|
+
)
|
20
|
+
}
|
21
|
+
|
22
|
+
export default HomeAddressStreetFormatting
|
data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_formatting_rails.md
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
The `state` prop will always capitalize the state name, even if the data entered is in lowercase. For example, when `state="pa"` is passed, it will be rendered as "PA". When you pass `preserve_case: true`, the street address will be rendered exactly as entered, without automatic title capitalization.
|
data/app/pb_kits/playbook/pb_home_address_street/docs/_home_address_street_formatting_react.md
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
The `state` prop will always capitalize the state name, even if the data entered is in lowercase. For example, when `state="pa"` is passed, it will be rendered as "PA". When you pass `preserveCase`, the street address will be rendered exactly as entered, without automatic title capitalization.
|
@@ -5,12 +5,14 @@ examples:
|
|
5
5
|
- home_address_street_emphasis: Emphasis
|
6
6
|
- home_address_street_modified: Modified
|
7
7
|
- home_address_street_link: Link
|
8
|
+
- home_address_street_formatting: Formatting
|
8
9
|
|
9
10
|
react:
|
10
11
|
- home_address_street_default: Default
|
11
12
|
- home_address_street_emphasis: Emphasis
|
12
13
|
- home_address_street_modified: Modified
|
13
14
|
- home_address_street_link: Link
|
15
|
+
- home_address_street_formatting: Formatting
|
14
16
|
|
15
17
|
swift:
|
16
18
|
- home_address_street_default_swift: Default
|
@@ -2,3 +2,4 @@ export { default as HomeAddressStreetDefault } from './_home_address_street_defa
|
|
2
2
|
export { default as HomeAddressStreetEmphasis } from './_home_address_street_emphasis.jsx'
|
3
3
|
export { default as HomeAddressStreetModified } from './_home_address_street_modified.jsx'
|
4
4
|
export { default as HomeAddressStreetLink } from './_home_address_street_link.jsx'
|
5
|
+
export { default as HomeAddressStreetFormatting } from './_home_address_street_formatting.jsx'
|
@@ -18,6 +18,7 @@ module Playbook
|
|
18
18
|
prop :state
|
19
19
|
prop :zipcode
|
20
20
|
prop :territory
|
21
|
+
prop :preserve_case, default: false
|
21
22
|
prop :dark, type: Playbook::Props::Boolean, default: false
|
22
23
|
|
23
24
|
def classname
|
@@ -29,7 +30,7 @@ module Playbook
|
|
29
30
|
end
|
30
31
|
|
31
32
|
def city_state
|
32
|
-
[city&.titleize, state].join(", ")
|
33
|
+
[city&.titleize, state&.upcase].join(", ")
|
33
34
|
end
|
34
35
|
|
35
36
|
def zip
|
@@ -37,7 +38,7 @@ module Playbook
|
|
37
38
|
end
|
38
39
|
|
39
40
|
def address_house_style
|
40
|
-
[
|
41
|
+
[format_street_address, house_style].join(separator)
|
41
42
|
end
|
42
43
|
|
43
44
|
def address_house_style2
|
@@ -48,6 +49,16 @@ module Playbook
|
|
48
49
|
house_style ? " \u00b7 " : ""
|
49
50
|
end
|
50
51
|
|
52
|
+
def format_street_address
|
53
|
+
preserve_case ? address : custom_titleize(address)
|
54
|
+
end
|
55
|
+
|
56
|
+
def custom_titleize(str)
|
57
|
+
return "" if str.nil?
|
58
|
+
|
59
|
+
str.split(" ").map(&:capitalize).join(" ")
|
60
|
+
end
|
61
|
+
|
51
62
|
def city_emphasis_props
|
52
63
|
{
|
53
64
|
address_house_style: address_house_style,
|
@@ -5,12 +5,8 @@
|
|
5
5
|
<%= object.icon.html_safe %>
|
6
6
|
</span>
|
7
7
|
<% else %>
|
8
|
-
<%=
|
9
|
-
|
10
|
-
data: object.data,
|
11
|
-
class: object.classname,
|
12
|
-
**combined_html_options
|
13
|
-
) %>
|
8
|
+
<%= pb_content_tag(:i) do %>
|
9
|
+
<% end %>
|
14
10
|
<%= content_tag(:span, nil,
|
15
11
|
aria: { label: "#{object.icon} icon" }.merge(object.aria),
|
16
12
|
hidden: true
|
@@ -1,9 +1,4 @@
|
|
1
|
-
<%=
|
2
|
-
aria: object.aria,
|
3
|
-
id: object.id,
|
4
|
-
data: object.data,
|
5
|
-
class: object.classname,
|
6
|
-
**combined_html_options) do %>
|
1
|
+
<%= pb_content_tag do %>
|
7
2
|
<%= pb_rails("body", props: {color: object.body_color}) do %>
|
8
3
|
<span style="<%= object.custom_color %>" class=<%= object.custom_color_class %>></span>
|
9
4
|
<%= pb_rails("title", props: { dark: object.dark, text: object.prefix_text, tag: "span", size: 4 }) %>
|