Glue is being EXTRA gluey when used in Function
- Dominant language
- JavaScript
- Stars
- 2.7k
- Forks
- 340
- PR merge metrics
- No merged PRs in 30d
Description
I made a bug report in INK. Load the example below as it will explain the issues it in detail.
-> lonedebug
=== lonedebug ===
#CLASS:__ui__
A series of weird glitches related to spacing between a variable called within a function and the space between it and glue being destoryed entirely. It will even pull in a tag out of the greyed out \#tag view and draw it in a normal story line view...
Error 0,1,2 and 3 highlight the destruction of the spacing found between the end of a variable and a glue marker.
Error 4 is a another test case
Error 5 is my current hack
+ (parsing) [Parsing]
#CLASS:__ui__
++ (glueerror)[Glue Errors]
+++ [Glue Error 0]
Pulls tags into inky viewer
~function0("nothing")
#CLASS:data
+++ [Glue Error 1]
Pulls tags into inky viewer
~function1("nothing")
#CLASS:data
+++ [Glue Error 2]
Expected ({function0("nothing")}{" "}{functionA("data")})
Is (<>
~function2("nothing")
~functionA("data")
<>)
+++ [Glue Error 3]
Expected ({function0("nothing")}{" "}{functionA("data")})
Is (<>
~function3("nothing")
~functionA("data")
<>)
+++ [Glue Error 4]
In this case the first empty space between the variable \{_value\} and \<\> is maintaned if a string detectable element (nbsp in this case) is placed after it. Any string placed between 2 glue connectors will preserve a single previous space placed between 2 glues or a variable and glue.
Expected ({function1("nothing")}{" "}{functionA("data")})
Is (<>
~function1("nothing")
~functionA("data")
<>)
+++ [Glue Error 5]
This is the only hack I figured out to fix the spacing issue, by embedding a space inside of a string blaced between brackets. Also placing the functions side by side within brackets and one on top of the other using \~ delimeter offer the same exact output so currently the only consistent method is this one.
Expected ({function1("nothing")}{functionB("data")})
Is (<>
~function1("nothing")
~functionB("data")
<>)
--- -> parsing
=== function function0(_value) ===
do:{_value} <>
=== function function1(_value) ===
do:{_value}{" "}<>
=== function function2(_value) ===
do:{_value} <>
=== function function3(_value) ===
do:{_value} <>\ <>
=== function functionA(_asset) ===
{"text"}
=== function functionB(_asset) ===
{" {"text"}"}
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.