Commit Graph

29 Commits

Author SHA1 Message Date
Martin Raifer
d5872cca73 show prettier maxChars warning for changeset comments
from #9392
2022-11-28 19:08:37 +01:00
alanb43
de23bd5c33 added warning when changeset comment length > 255 chars 2022-11-27 01:55:30 -05:00
Martin Raifer
9f3f8e1366 rename method 2021-11-29 19:26:18 +01:00
Martin Raifer
d78c357588 replace raw html injection of localized texts
by using d3 to insert the localized text spans directly into the DOM
2021-11-26 18:51:45 +01:00
Quincy Morgan
5435082d9c Revert t function to returning the plain string by default
Add `t.html` function for getting the string with the `lang` attribute
2020-09-22 12:03:29 -04:00
Quincy Morgan
a3549f9a76 Merge branch 'develop' into lang-attributes
# Conflicts:
#	modules/ui/commit_warnings.js
#	modules/ui/field.js
#	modules/ui/fields/wikidata.js
#	modules/ui/fields/wikipedia.js
#	modules/ui/full_screen.js
#	modules/ui/panels/history.js
#	modules/ui/sections/entity_issues.js
#	modules/ui/sections/map_features.js
#	modules/ui/sections/raw_member_editor.js
#	modules/ui/sections/validation_rules.js
#	modules/ui/tag_reference.js
2020-09-22 10:55:07 -04:00
Quincy Morgan
58014ace62 Don't prevent default tabbing to elements (re: #8004) 2020-09-17 12:07:20 -04:00
Quincy Morgan
32f8274929 Make t function return a span element with a lang attribute unless html: false is specified in the options (re: #7963)
Update `text` functions to `html` to support inserting the `span` elements
Specify `html: false` for various instances where a `span` is not desired, e.g. `placeholder` and `title` attributes
2020-09-15 21:56:22 -04:00
Quincy Morgan
60f7dc7c0b Replace presets property of context with singleton
Remove utilPreset
2020-04-01 13:08:45 -07:00
Quincy Morgan
a1af118f0e Ensure locales and presets are loaded before the UI loads (close #7406)
Consolidate localization behavior and init to a coreLocalizer function and singleton
Explicitly support `en-US` locale
Rename coreData to coreFileFetcher and export a singleton rather than using a property of coreContext
Add `apiConnections` property of coreContext to simplify adding a source switcher
Replace some init functions with re-callable, promise-supporting `ensureLoaded` functions
Make coreContext itself load the UI if a container has been specified at init time
Fix code tests
2020-03-31 12:23:31 -07:00
Quincy Morgan
5a0d0bf653 Fix focusing of changeset comment field upon save 2020-03-24 13:01:30 -07:00
Quincy Morgan
628b53eff6 Fix error upon changing raw changeset tags 2020-03-23 14:07:40 -07:00
Quincy Morgan
d01bb78707 Reduce circular dependencies caused by importing from indexes, the location of the validation models, and the location of areaKeys (close #6237) 2019-04-24 13:45:59 -07:00
Bryan Housel
3896b2282f Remove lodash isNaN, isNumber, isString, bind, uniqBy
(re: 6087)
2019-03-27 23:11:45 -04:00
Bryan Housel
39b3f1df68 Avoid creating comboboxes
(closes #5568)

Several strategies in here:
- Move uiCombobox() from inside the render function to class variable
- Don't render stuff like the raw tag editor when it's collapsed
- Don't show as many fields/combos on hover
- Don't instantiate fields (like universal/more) until they're actually shown
- Bind the combo on enter selection not on update selection
2018-12-11 16:07:00 -05:00
Bryan Housel
15a54cab17 Use context.container instead of passing it in 2018-12-10 14:14:27 -05:00
Bryan Housel
e5dedeff8b Move lib/d3.combobox.js -> ui/combobox.js
As with other things from this lib/ folder, little original code remains
and turning these things into reusable d3 plugins is not a priority.
2018-12-10 12:38:21 -05:00
Bryan Housel
470835b38f Extract all graphics from iD sprite, reassemble with svg-sprite
All iD sprite graphics are now prefixed with `iD-`
Also includes support for sending the preset logos to taginfo
2018-06-08 16:06:46 -04:00
Bryan Housel
d8f6fafe74 Don't add empty source tag on a changeset
(closes #4993)
2018-04-18 17:33:56 -04:00
Bryan Housel
3d13620705 Convert lodah-es and d3 to named imports for ui 2017-09-26 11:22:43 -04:00
Bryan Housel
4cf357f61a Add code to extract hashtags from changeset comment 2017-08-16 00:30:34 -04:00
Bryan Housel
09a661c718 Restore "good changeset comments" link in tag-reference section
Also includes a bunch of css cleanups for the tag-reference section
to fix style for readonly raw-tag-editor rows and adjust margin widths
2017-08-15 13:12:57 -04:00
Bryan Housel
7563f3ac16 Refactor duplicate form-field code to uiFormFields 2017-08-15 09:35:57 -04:00
Bryan Housel
194b56c0f0 Restore the comment google warning 2017-08-14 22:59:15 -04:00
Bryan Housel
e6eff907a2 Restore the previous changeset dropdown 2017-08-14 12:46:10 -04:00
Bryan Housel
4971a20409 Pacify eslint 2017-08-13 23:42:06 -04:00
Bryan Housel
9b37ac7b6c Fix errors with changeset fields and warnings, improve styles 2017-08-13 23:25:37 -04:00
Bryan Housel
e0266da083 WIP: add changeset fields and refactor 2017-08-12 14:26:34 -04:00
Bryan Housel
439eed4b39 WIP: refactor uiCommit into sections, introduce uiChangesetEditor
uiCommit is getting kind of big as we add more to the commit pane.

I'm going to split it up and put the field rendering code into a separate
module, similar to how uiEntityEditor embeds uiPresetEditor for the fields.

This allows us to add a few more fields that users can set on their changesets
(like hashtags, source), and even hide them under a "Add field" dropdown.
2017-08-11 17:17:46 -04:00