discourse/app/assets/javascripts
zogstrip aaec80413d FIX: fast edit with a typographic character
When a post containing an apostrophe (') is being cooked, the apostrophe is being converted to the "typographic" version (’) (because we enable markdown-it's **typographer** mode by default in Discourse)

When you select text that contains such apostrophe and then try to save your fast edit, it fails miserably without any error.

That's because when you select text from the DOM, it uses the cooked version which has the typographic apostrophe.

When you save your fast edit, we fetch the raw version of the post, which has the "regular" apostrophe. Thus doing `raw.replace(selectedText, editedText)` doesn't work because `raw` has the regular apostrophe but `selectedText` has the typographic apostrophe.

Since it's somewhat complicated to handle all typographic characters, we would basically have to reverse the process done in `custom-typographer-replacements.js`, we instead bail out and show the composer when we detect such character in the selection.

Internal ref - t/143836
2024-12-10 12:13:10 +01:00
..
admin UX: Copy for feature feed toggle (#30196) 2024-12-10 16:24:15 +10:00
custom-proxy Build(deps-dev): Bump express from 4.21.1 to 4.21.2 (#30167) 2024-12-08 23:35:23 +01:00
deprecation-silencer DEV: Reformat package.json files (#28733) 2024-09-04 21:14:13 +02:00
dialog-holder Build(deps-dev): Bump webpack from 5.97.0 to 5.97.1 (#30138) 2024-12-05 23:52:02 +01:00
discourse FIX: fast edit with a typographic character 2024-12-10 12:13:10 +01:00
discourse-common Build(deps-dev): Bump webpack from 5.97.0 to 5.97.1 (#30138) 2024-12-05 23:52:02 +01:00
discourse-hbr DEV: Detect hbr topic list customizations (#29793) 2024-11-21 16:00:49 +01:00
discourse-i18n DEV: add i18n named export to "discourse-i18n" (#29820) 2024-11-19 11:25:22 +00:00
discourse-markdown-it FIX: properly quote videos (#30099) 2024-12-04 12:39:38 +01:00
discourse-plugins Build(deps-dev): Bump webpack from 5.97.0 to 5.97.1 (#30138) 2024-12-05 23:52:02 +01:00
discourse-widget-hbs Build(deps-dev): Bump webpack from 5.97.0 to 5.97.1 (#30138) 2024-12-05 23:52:02 +01:00
docs
ember-addons
ember-cli-progress-ci
ember-production-deprecations DEV: Update ember-cli-deprecation-workflow from 2.2.0 to 3.0.1 (#28226) 2024-08-07 17:59:42 +02:00
float-kit Build(deps-dev): Bump webpack from 5.97.0 to 5.97.1 (#30138) 2024-12-05 23:52:02 +01:00
locales
pretty-text Build(deps-dev): Bump webpack from 5.97.0 to 5.97.1 (#30138) 2024-12-05 23:52:02 +01:00
select-kit FIX: ensures sk can be scrolled on iOS in a modal (#30164) 2024-12-09 09:53:22 +10:00
theme-transpiler Build(deps): Bump terser from 5.36.0 to 5.37.0 (#30139) 2024-12-05 23:18:45 +01:00
truth-helpers Build(deps): Bump ember-auto-import from 2.9.0 to 2.10.0 (#29606) 2024-11-06 01:06:08 +01:00
.npmrc
handlebars-shim.js
polyfills.js DEV: Bump eslint, lint-configs, and move to flat config (#29661) 2024-11-12 12:33:17 +00:00
service-worker.js.erb DEV: allow non focused tab to be primary tab in service worker (#29516) 2024-11-01 09:42:33 +04:00