Skip to content

Commit 9ac970a

Browse files
committed
Refine description for x0shift/x1shift/y0shift/y1shift
1 parent 7de45c3 commit 9ac970a

File tree

2 files changed

+16
-12
lines changed

2 files changed

+16
-12
lines changed

src/components/shapes/attributes.js

+12-8
Original file line numberDiff line numberDiff line change
@@ -176,8 +176,9 @@ module.exports = templatedArray('shape', {
176176
max: 1,
177177
editType: 'calc',
178178
description: [
179-
'Only relevant if `xref` is a (multi-)category axes. Shifts `x0` by a fraction of the',
180-
'reference unit. E.g. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.'
179+
'Shifts `x0` away from the center of the category when `xref` is a *category* or',
180+
'*multicategory* axis. -0.5 corresponds to the start of the category and 0.5',
181+
'corresponds to the end of the category.'
181182
].join(' ')
182183
},
183184
x1shift: {
@@ -187,8 +188,9 @@ module.exports = templatedArray('shape', {
187188
max: 1,
188189
editType: 'calc',
189190
description: [
190-
'Only relevant if `xref` is a (multi-)category axes. Shifts `x1` by a fraction of the',
191-
'reference unit. E.g. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.'
191+
'Shifts `x1` away from the center of the category when `xref` is a *category* or',
192+
'*multicategory* axis. -0.5 corresponds to the start of the category and 0.5',
193+
'corresponds to the end of the category.'
192194
].join(' ')
193195
},
194196
yref: extendFlat({}, annAttrs.yref, {
@@ -248,8 +250,9 @@ module.exports = templatedArray('shape', {
248250
max: 1,
249251
editType: 'calc',
250252
description: [
251-
'Only relevant if `yref` is a (multi-)category axes. Shifts `y0` by a fraction of the',
252-
'reference unit. E.g. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.'
253+
'Shifts `y0` away from the center of the category when `yref` is a *category* or',
254+
'*multicategory* axis. -0.5 corresponds to the start of the category and 0.5',
255+
'corresponds to the end of the category.'
253256
].join(' ')
254257
},
255258
y1shift: {
@@ -259,8 +262,9 @@ module.exports = templatedArray('shape', {
259262
max: 1,
260263
editType: 'calc',
261264
description: [
262-
'Only relevant if `yref` is a (multi-)category axes. Shifts `y1` by a fraction of the',
263-
'reference unit. E.g. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.'
265+
'Shifts `y1` away from the center of the category when `yref` is a *category* or',
266+
'*multicategory* axis. -0.5 corresponds to the start of the category and 0.5',
267+
'corresponds to the end of the category.'
264268
].join(' ')
265269
},
266270
path: {

test/plot-schema.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -10006,7 +10006,7 @@
1000610006
"valType": "any"
1000710007
},
1000810008
"x0shift": {
10009-
"description": "Only relevant if `xref` is a (multi-)category axes. Shifts `x0` by a fraction of the reference unit. E.g. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.",
10009+
"description": "Shifts `x0` away from the center of the category when `xref` is a *category* or *multicategory* axis. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.",
1001010010
"dflt": 0,
1001110011
"editType": "calc",
1001210012
"max": 1,
@@ -10019,7 +10019,7 @@
1001910019
"valType": "any"
1002010020
},
1002110021
"x1shift": {
10022-
"description": "Only relevant if `xref` is a (multi-)category axes. Shifts `x1` by a fraction of the reference unit. E.g. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.",
10022+
"description": "Shifts `x1` away from the center of the category when `xref` is a *category* or *multicategory* axis. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.",
1002310023
"dflt": 0,
1002410024
"editType": "calc",
1002510025
"max": 1,
@@ -10056,7 +10056,7 @@
1005610056
"valType": "any"
1005710057
},
1005810058
"y0shift": {
10059-
"description": "Only relevant if `yref` is a (multi-)category axes. Shifts `y0` by a fraction of the reference unit. E.g. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.",
10059+
"description": "Shifts `y0` away from the center of the category when `yref` is a *category* or *multicategory* axis. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.",
1006010060
"dflt": 0,
1006110061
"editType": "calc",
1006210062
"max": 1,
@@ -10069,7 +10069,7 @@
1006910069
"valType": "any"
1007010070
},
1007110071
"y1shift": {
10072-
"description": "Only relevant if `yref` is a (multi-)category axes. Shifts `y1` by a fraction of the reference unit. E.g. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.",
10072+
"description": "Shifts `y1` away from the center of the category when `yref` is a *category* or *multicategory* axis. -0.5 corresponds to the start of the category and 0.5 corresponds to the end of the category.",
1007310073
"dflt": 0,
1007410074
"editType": "calc",
1007510075
"max": 1,

0 commit comments

Comments
 (0)