aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/htmlinputelement.rs
Commit message (Collapse)AuthorAgeFilesLines
* Strict import formatting (grouping and granularity) (#30325)Samson2023-09-111-36/+37
| | | | | * strict imports formatting * Reformat all imports
* remove `extern crate` (#30311)Samson2023-09-081-1/+1
| | | | | | | | | | | * remove extern crate * Update components/script_plugins/lib.rs Co-authored-by: Martin Robinson <mrobinson@igalia.com> --------- Co-authored-by: Martin Robinson <mrobinson@igalia.com>
* Fix warnings after chrono upgrade (#30165)Martin Robinson2023-08-231-38/+48
| | | | Some functions are now deprecated, so use the suggested ones and do a general cleanup of the affected lines of code.
* No tracing of nop traceable fields (#29926)Samson2023-08-041-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add `no_trace` option to JSTraceable derive * NoTrace wrapper * Port some types to no_trace schematics * Fixing my unsafe mistakes (not tracing traceables) * Add docs & safety guards for no_trace Safety guards (trait shenanigans) guarantees safety usage of `no_trace` * Port canvas_traits to no_trace * Port servo_media to no_trace * Port net_traits to no_trace * Port style to no_trace * Port webgpu to no_trace * Port script_traits to no_trace * Port canvas_traits, devtools_traits, embedder_traits, profile_traits to no_trace * unrooted_must_root lint in seperate file * Add trace_in_no_trace_lint as script_plugin * Composable types in must_not_have_traceable * Introduced HashMapTracedValues wrapper * `HashMap<NoTrace<K>,V>`->`HashMapTracedValues<K,V>` * Port rest of servo's types to no_trace * Port html5ever, euclid, mime and http to no_trace * Port remaining externals to no_trace * Port webxr and Arc<Mutex<_>> * Fix spelling in notrace doc
* Implement :valid :invalid pseudo classes (#26729)John Poge II2023-07-211-10/+27
| | | Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* Support arbitrary protos when wrapping DOM objects with constructors.Josh Matthews2023-05-281-1/+3
|
* Make GlobalScope.get_cx a static method.Josh Matthews2023-05-201-1/+1
|
* Further changes required by ServoOriol Brufau2023-05-191-1/+1
|
* Make HTMLInputElement.list an HTMLDataListElement2shiori172023-03-021-6/+3
| | | | Signed-off-by: 2shiori17 <98276492+2shiori17@users.noreply.github.com>
* Update nightly rustc.Josh Matthews2021-11-011-3/+3
|
* Make hidden input _charset_ check case insensitiveVincent Ricard2020-10-091-1/+1
|
* Remove unnecessary checksVincent Ricard2020-09-241-13/+0
|
* Allow mutating <input disabled type=checkbox/radio>Vincent Ricard2020-09-241-7/+10
|
* Implement HTMLFormElement.requestSubmit()Also includes a fix for reentrant ↵Maxim Tsoy2020-07-021-0/+6
| | | | form submission behavior
* Update document focus when element focusability changes.Josh Matthews2020-06-151-0/+2
|
* Make clicking on an element request focus for focusable elements.Josh Matthews2020-06-151-1/+0
|
* Form constraints validationteapotd2020-04-021-18/+431
|
* Introduce more layout helpers to make selection_for_layout be safeAnthony Ramine2020-04-011-9/+16
|
* Introduce <LayoutDom<Element>>::focus_stateAnthony Ramine2020-04-011-1/+1
|
* Introduce a bunch of LayoutDom<HTMLInputElement> private helpersAnthony Ramine2020-04-011-30/+31
| | | | Those help contain the unsafety in most of the actual helpers used by layout.
* Introduce <LayoutDom<Element>>::attrs()Anthony Ramine2020-03-311-7/+5
| | | | | | This safe method is the basic block to access element attributes from layout. We reuse it in the other attr-related layout methods to remove a pretty big source of rampant unsafe code between script and layout.
* Merge RawLayoutElementHelpers into LayoutElementHelpersAnthony Ramine2020-03-311-4/+1
|
* Make LayoutHTMLInputElementHelpers::value_for_layout return a cowAnthony Ramine2020-03-311-25/+30
|
* Give a lifetime parameter to LayoutDomAnthony Ramine2020-03-281-2/+5
|
* Add trait DomObjectWrap to provide WRAP functionYUAN LYU2020-03-201-2/+0
|
* Accept only connected attributes for checkbox and radio activation behaviourDmitry Kolupaev2020-03-111-0/+3
|
* Implement step 5.13 for dirname correctlyDmitry Kolupaev2020-02-251-2/+2
|
* Add special case directionality of phone inputDmitry Kolupaev2020-02-251-1/+0
|
* Rearrange directionality algorithm functionsDmitry Kolupaev2020-02-251-26/+8
|
* Move dirname collection to inputDmitry Kolupaev2020-02-251-2/+16
|
* Implement dirname for form submit and directionality for elementDmitry Kolupaev2020-02-251-0/+36
|
* Auto merge of #25488 - pshaughn:clickactivate, r=jdmbors-servo2020-02-131-119/+90
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Event dispatch rewritten to align to spec, activate on clicks better I went over the changes to the event dispatch spec that had accumulated over the past few years, rewriting dispatch/invoke/inner-invoke almost completely and modifying other code where it was relevant. Most of the remaining obvious deviations from spec are things that will only come up when we start handling events in shadow DOM. I am pushing now because I want to see CI test results, but please do not approve this PR just if automated test improvements look good. I may have broken some actual UI interactions in the course of fixing synthetic events, and some manual testing is needed, including checking that manual interactions with interactive content continue to fire the events they're supposed to. --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #25384 and fix #22783 and fix #25199 <!-- Either: --> - [ ] There are automated tests for the synthetic-click parts of these changes, BUT the effects on real UI events need some manual testing before merging <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
| * Event dispatch rewritten to resemble spec more often, activate on clicks betterPatrick Shaughnessy2020-02-121-119/+90
| |
* | Names should now be consistently atomsPatrick Shaughnessy2020-02-131-5/+7
|/
* SubmitEvent and test changesPatrick Shaughnessy2020-01-301-1/+1
|
* Auto merge of #25490 - teapotd:radio-group-iter, r=Manishearthbors-servo2020-01-231-53/+49
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Simplify and fix iteration over radio button group - Code for iterating over radio button group elements has been extracted to `radio_group_iter` - `in_same_group` now checks if elements are in the same tree - `radio_group_name` returns `None` if name is empty - Radio buttons now group together in orphan trees (#25486) --- - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #25486 - [ ] There are tests for these changes
| * Simplify and fix iteration over radio button groupteapotd2020-01-111-53/+49
| |
* | Modify `script` to prevent further violations of snake_caseKunal Mohan2020-01-181-1/+2
|/
* stepUp, stepDown, valueAsNumber, valueAsDate, and list work and have testsPatrick Shaughnessy2020-01-101-8/+651
|
* Labels are a live list in tree orderPatrick Shaughnessy2020-01-061-4/+12
|
* Auto merge of #25397 - teapotd:input-cloning-steps, r=jdmbors-servo2020-01-031-1/+21
|\ | | | | | | | | | | | | | | | | | | | | | | Implement HTMLInputElement cloning steps This change adds missing [cloning steps for input elements](https://html.spec.whatwg.org/multipage/#the-input-element%3Aconcept-node-clone-ext). --- - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #25385 - [X] There are tests for these changes
| * Implement HTMLInputElement cloning stepsteapotd2019-12-261-1/+21
| |
* | Radio button grouping is now case-sensitivePatrick Shaughnessy2019-12-311-2/+1
|/
* hidden field named _charset_ now appears in FormData as UTF-8 to fix #25150Patrick Shaughnessy2019-12-091-9/+28
|
* Auto merge of #24626 - glowe:issue-21810/improve-validation-methods, r=jdmbors-servo2019-12-031-1/+10
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Issue 21810/improve validation methods <!-- Please describe your changes on the following line: --> This is a start at addressing #21810. I'm putting these changes out early to get some feedback on the following items: 1. I added unit tests for the validation methods mentioned in #21810, because I couldn't tell whether any of the existing WPT tests covered them. Are these tests worthwhile? Are any of them unnecessary? 2. I changed the implementation for `is_valid_floating_point_number_string` so that it passed the tests. The previous version of the function wasn't restrictive enough (it allowed certain whitespace characters before the number string). 3. I changed the catch-all condition in `htmlinputelement.rs` to account for the remaining input types that don't have a value sanitization algorithm. This last change seems good to me since we won't be able to add a new input type without adding it to the case and checking the spec for an algorithm. --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes fix #21810 <!-- Either: --> - [x] There are tests for these changes <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
| * Remove catch-all case for input sanitizationglowe2019-11-301-1/+10
| | | | | | | | | | | | | | Replaced catch-all with explicit case for inputs that do not have a value sanitization algorithm. This should prevent us from forgetting to implement a sanitization for an input, since they must all be accounted for in the match expression.
* | Use `#![register_tool]` instead of `#![register_attr]`Simon Sapin2019-11-151-1/+1
|/ | | | CC https://github.com/rust-lang/rust/issues/66079
* [WIP] solve #22782takumi2019-10-181-69/+69
| | | | TODO: write tests for my change
* Upgrade to rustc 1.39.0-nightly (f7af19c27 2019-08-15)Simon Sapin2019-08-231-1/+1
|
* Upgrade to rustc 1.38.0-nightly (dddb7fca0 2019-07-30)Simon Sapin2019-07-311-5/+7
|