mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-23 21:02:25 +01:00
Turn off white-space:pre for the completions list
This commit is contained in:
@@ -112,12 +112,12 @@ const template = {
|
|||||||
if (str == "")
|
if (str == "")
|
||||||
return <>{str}</>;
|
return <>{str}</>;
|
||||||
|
|
||||||
XML.ignoreWhitespace = false;
|
|
||||||
str = String(str).replace(" ", "\u00a0");
|
str = String(str).replace(" ", "\u00a0");
|
||||||
let s = <></>;
|
let s = <></>;
|
||||||
let start = 0;
|
let start = 0;
|
||||||
for (let [i, length] in iter)
|
for (let [i, length] in iter)
|
||||||
{
|
{
|
||||||
|
XML.ignoreWhitespace = false;
|
||||||
s += <>{str.substring(start, i)}</>;
|
s += <>{str.substring(start, i)}</>;
|
||||||
s += <span class="hl-Filter">{str.substr(i, length)}</span>;
|
s += <span class="hl-Filter">{str.substr(i, length)}</span>;
|
||||||
start = i + length;
|
start = i + length;
|
||||||
|
|||||||
@@ -235,7 +235,7 @@ function CommandLine() //{{{
|
|||||||
*/
|
*/
|
||||||
XML.ignoreWhitespace = typeof str == "xml";
|
XML.ignoreWhitespace = typeof str == "xml";
|
||||||
var output = <div class={"ex-command-output " + highlightGroup} style={"min-width: " + commandlineWidget.scrollWidth + "px"}>{template.maybeXML(str)}</div>;
|
var output = <div class={"ex-command-output " + highlightGroup} style={"min-width: " + commandlineWidget.scrollWidth + "px"}>{template.maybeXML(str)}</div>;
|
||||||
XML.ignoreWhiteSpace = true;
|
XML.ignoreWhitespace = true;
|
||||||
|
|
||||||
lastMowOutput = output;
|
lastMowOutput = output;
|
||||||
|
|
||||||
@@ -1321,7 +1321,6 @@ function ItemList(id) //{{{
|
|||||||
if (typeof a == "function")
|
if (typeof a == "function")
|
||||||
a = a();
|
a = a();
|
||||||
|
|
||||||
XML.ignoreWhitespace = true;
|
|
||||||
let row =
|
let row =
|
||||||
<ul class="hl-CompItem">
|
<ul class="hl-CompItem">
|
||||||
<li class="hl-CompIcon">{a ? <img src={a}/> : <></>}</li>
|
<li class="hl-CompIcon">{a ? <img src={a}/> : <></>}</li>
|
||||||
@@ -1372,9 +1371,10 @@ function ItemList(id) //{{{
|
|||||||
|
|
||||||
|
|
||||||
// do a full refill of the list:
|
// do a full refill of the list:
|
||||||
|
|
||||||
XML.ignoreWhitespace = true;
|
XML.ignoreWhitespace = true;
|
||||||
let div = <div class="ex-command-output hl-Normal">
|
let minWidth = document.getElementById("liberator-commandline").scrollWidth;
|
||||||
|
let div = <div class="ex-command-output hl-Normal"
|
||||||
|
style={"white-space: normal; min-width: " + minWidth + "px"}>
|
||||||
<span class="hl-Title">Completions:</span>
|
<span class="hl-Title">Completions:</span>
|
||||||
<div class="hl-Completions">
|
<div class="hl-Completions">
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user