aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/htmlinputelement.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/script/dom/htmlinputelement.rs')
-rwxr-xr-xcomponents/script/dom/htmlinputelement.rs18
1 files changed, 16 insertions, 2 deletions
diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs
index 298af937a32..7141f9a4537 100755
--- a/components/script/dom/htmlinputelement.rs
+++ b/components/script/dom/htmlinputelement.rs
@@ -1473,11 +1473,25 @@ impl HTMLInputElement {
}
// Step 5.12
- vec![FormDatum {
+ let mut result = vec![FormDatum {
ty: ty.clone(),
name: name,
value: FormDatumValue::String(self.Value()),
- }]
+ }];
+
+ // 4.10.18.2
+ // https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#submitting-element-directionality:-the-dirname-attribute
+ let dirname: DOMString = self.DirName();
+ let directionality = DOMString::from(self.directionality("auto"));
+ if !dirname.is_empty() {
+ result.push(FormDatum {
+ ty: ty.clone(),
+ name: dirname.clone(),
+ value: FormDatumValue::String(directionality),
+ });
+ }
+
+ result
}
// https://html.spec.whatwg.org/multipage/#radio-button-group