Page MenuHomePhabricator

[TUX] Improve insertables insertion to replace selected text
Open, LowPublic

Description

Currently with using insertables their codes is inserted at left of the cursor or selected text. Selection thus canceled.
See example


and current result (highlighted)

Proposal: when insertion to replace selected text by a insertable code. Target results may be look as:

This would more user-friendly behavior.

Also reported on https://translatewiki.net/wiki/Thread:Support/Editing_in_the_AJAX_tool_-_using_klick_point_in_the_lower_left_edge.

Event Timeline

Kaganer created this task.Sep 29 2015, 12:28 PM
Kaganer assigned this task to Nikerabbit.
Kaganer raised the priority of this task from to Needs Triage.
Kaganer updated the task description. (Show Details)
Kaganer added subscribers: Kaganer, Pginer-WMF, Nemo_bis and 2 others.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptSep 29 2015, 12:28 PM
Kaganer renamed this task from [TUX] Update insertables insertion to replace selected text to [TUX] Improve insertables insertion to replace selected text.Sep 29 2015, 12:31 PM
Kaganer updated the task description. (Show Details)
Kaganer set Security to None.

How would you know when to replace the existing selection and when to wrap the selection (for example {{PLURAL:$1|_}} wraps the selection at _)?

Nikerabbit triaged this task as Low priority.Sep 29 2015, 6:45 PM

I don't see problem.

  1. "simple" insertables, as variables $1 or $name etc. should be replace the selection
  2. "complicated" insertables (currently this only {{PLURAL:$1|+}} and {{GENDER:$1|+}}. not?) should be wrap the selection

Difference - presence or absence of brackets.

Nikerabbit removed Nikerabbit as the assignee of this task.Apr 20 2016, 1:02 PM
Nikerabbit added a subscriber: Nikerabbit.

I am not currently working on this.

Glaisher updated the task description. (Show Details)Aug 8 2016, 5:35 PM
Glaisher added subscribers: Purodha, Glaisher.