Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
MUR Drupal
d3_sankey
Commits
83df3cec
Commit
83df3cec
authored
Sep 27, 2016
by
M Parker
Browse files
Add field suffixes to textfields with units in pixels.
parent
8264e936
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
modules/d3_sankey_table_group_pp/d3_sankey_table_group_pp.module
.../d3_sankey_table_group_pp/d3_sankey_table_group_pp.module
+4
-0
No files found.
modules/d3_sankey_table_group_pp/d3_sankey_table_group_pp.module
View file @
83df3cec
...
...
@@ -65,6 +65,7 @@ function d3_sankey_table_group_pp_field_formatter_settings_form($field, $instanc
$element
[
'width'
]
=
array
(
'#type'
=>
'textfield'
,
'#title'
=>
t
(
'Chart width'
),
'#field_suffix'
=>
t
(
'px'
,
array
(),
array
(
'context'
=>
'unit of measurement (pixels)'
)),
'#element_validate'
=>
array
(
'element_validate_integer_positive'
),
'#default_value'
=>
$settings
[
'width'
],
);
...
...
@@ -73,6 +74,7 @@ function d3_sankey_table_group_pp_field_formatter_settings_form($field, $instanc
$element
[
'height'
]
=
array
(
'#type'
=>
'textfield'
,
'#title'
=>
t
(
'Chart height'
),
'#field_suffix'
=>
t
(
'px'
,
array
(),
array
(
'context'
=>
'unit of measurement (pixels)'
)),
'#element_validate'
=>
array
(
'element_validate_integer_positive'
),
'#default_value'
=>
$settings
[
'height'
],
);
...
...
@@ -81,6 +83,7 @@ function d3_sankey_table_group_pp_field_formatter_settings_form($field, $instanc
$element
[
'nodeWidth'
]
=
array
(
'#type'
=>
'textfield'
,
'#title'
=>
t
(
'Node width'
),
'#field_suffix'
=>
t
(
'px'
,
array
(),
array
(
'context'
=>
'unit of measurement (pixels)'
)),
'#element_validate'
=>
array
(
'element_validate_integer_positive'
),
'#default_value'
=>
$settings
[
'nodeWidth'
],
);
...
...
@@ -89,6 +92,7 @@ function d3_sankey_table_group_pp_field_formatter_settings_form($field, $instanc
$element
[
'nodePadding'
]
=
array
(
'#type'
=>
'textfield'
,
'#title'
=>
t
(
'Node padding'
),
'#field_suffix'
=>
t
(
'px'
,
array
(),
array
(
'context'
=>
'unit of measurement (pixels)'
)),
'#element_validate'
=>
array
(
'element_validate_integer_positive'
),
'#default_value'
=>
$settings
[
'nodePadding'
],
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment