ollicle/BBEdit-Extract-Placeholder 7
A key press minimising script to extract and apply text from BBEdit Clippings placeholders.
Lint JavaScript within BBEdit using ESLint. Errors and warnings are opened in a results window within BBEdit using the BBEdit command line tool bbresults.
Bookmarklet to remove fixed position elements with a tap
A community–driven effort to make web accessibility easier.
ollicle/aarongustafson.github.io 0
My website
Raw browser/feature support data from caniuse.com
My version of a custom select input, with filtering
Monospaced font with programming ligatures
Flipping awesome animations.
A CLI workflow for the administration of Mac applications distributed as binaries
startednaver/egjs-flicking
started time in 14 hours
issue commenttonsky/FiraCode
Missing bars on palatalized Komi letters
Perfect, thanks! Will fix
comment created time in 2 days
issue commenttonsky/FiraCode
Missing bars on palatalized Komi letters
I have added red bars to roughly show what is missing. Some of these bars nearly overlap the following characters; this is because Fira Code’s current glyphs put too much emphasis on their palatalization curves, so I didn’t have enough room for sufficient right side bearings. For example, the width of the glyph for U+050B CYRILLIC SMALL LETTER KOMI NJE is about half ⟨н⟩ on the left and half palatalization curve on the right, whereas the primary sources I linked earlier show the curve is generally quite narrow.
Another problem is the construction of ⟨Ԍ⟩ and ⟨ԍ⟩. They are not based on the Latin letter ⟨G⟩. If the other Komi letters have smooth palatalization curves, so should these, but they currently have sharp corners, which I have marked with blue rectangles.
comment created time in 2 days
issue commenttonsky/FiraCode
Missing bars on palatalized Komi letters
Can (very roughly) show on this picture which part is missing? Preferably in another color (red or blue)?
comment created time in 2 days
issue openedtonsky/FiraCode
Missing bars on palatalized Komi letters
The palatalized Komi letters U+0502..U+0505 and U+0508..U+050F should have horizontal bars upon their upwards curls. In version 5.2, U+050C..U+050D have only the left half of the bar, and the rest have no bar at all.
The bar is not a mere serif: it does appear in sans-serif fonts. There are plenty of examples in the “на молодцовском алфавите 1920-тых годов” section of this Komi book list. In all the sans-serif text in those books, I have only found two counterexamples, both on the title page of Шонді југӧр (1926) in “ЛЫԂԂӦГПАНЫԌ”, though the rest of the sans-serif text within that book follows the general pattern. Here is another Komi book list.
created time in 2 days
issue commenttonsky/FiraCode
Remove OTF from distr to avoid confusion
I think it's important to point out that in particular Fira Code is a programming fonts with programming ligatures. These cease to work when the TTF version is installed in lieu of the OTF version (as I found out today).
comment created time in 2 days
issue commenttonsky/FiraCode
VS Code doesn't recognizes Fira Code
See the installation documentation https://github.com/tonsky/FiraCode/wiki/Installing#windows.
"On some systems (especially Windows 10), you may need to "Unblock" each font file before installing. To do so, right-click each font file, click Properties, then check Unblock next to Security at the bottom of the General tab. Click OK, and then install. Note: Skipping this step may cause the Fira Code fonts to intermittently stop working in VS Code, even though the fonts still appear in other programs."
comment created time in 2 days
issue commenttonsky/FiraCode
Horizontal and vertical gaps on some hyphen/equal based ligatures
Subscribe this issue as I noticed the same behavior. As I understand it, the current workaround is to use Fira Code 3.1 which doesn't have the infinite-length feature which causes the issue. I'm myself not so much interested in the infinite-length feature so will go back on 3.1, it's a bit too noticeable in Kitty (and probably other editors as well). Thank you for your work on this font, it really is awesome!
comment created time in 2 days
pull request commentstimulusjs/stimulus
Pass data attributes as action method argument
Ok this has been standing for too LONG sorry about that. I finally updated this PR
Params as a property of the event
I have implemented the recommendation of @javan for passing the params as a new property of the event
<div data-controller="item spinner">
<button data-action="item#upvote spinner#start"
data-item-id-param="12345"
data-item-url-param="/votes"
data-item-payload-param='{"value":"1234567"}'
data-item-active-param="true">…</button>
</div>
upvote({ params }) {
console.log(params) // { id: 12345, url: "/votes", active: true, payload: { value: 1234567 } }
}
Automatically type cast
As per the suggestion the params are automatically casted.
| Data attribute | Param | Type |
|---|---|---|
data-item-id-param="12345" |
12345 | Number |
data-item-url-param="/votes" |
"/votes" | String |
data-item-payload-param='{"value":"1234567"}' |
{ value: 1234567 } | Object |
data-item-active-param="true" |
true |
Boolean |
Controller namespacing
The params are namespaced by controllers so in the above example the start action of the spinnercontroller does not receive any params.
start({ params }) {
console.log(params) // { }
}
Function namespacing
I have not implemented the namespacing by function as discussed in some comments above
current implementation is data-controllerIdentifier-paramName-param
data-item-url-param="/votes"
rather than
data-item-upvote-url-param="/votes"
Rational : It feels closer to the value and class API and as pointed by @dancallaghan it could introduce some collusion.
This could be easily changed if needed
Tests
I tried testing several edge cases
- multiple word param
- invalid param syntax
- updating manually the params value
- clicking nested elements
Documentation
No documentation added at this point
Comments and suggestions welcome 🙏
comment created time in 3 days
issue commenttonsky/FiraCode
Feasibility of dual color font
The following result I achieved applying:
Edditing body and .minimap, .editor-scrollable>.decorationsOverviewRuler of \.vscode\extensions\eyhn.vscode-vibrancy-1.0.9\themes\Default Dark.css to:
.minimap, .editor-scrollable>.decorationsOverviewRuler {
opacity: 0.4;
}
body {
background: transparent !important;
-webkit-font-smoothing: antialiased;
-webkit-text-stroke: 0.2px black;
text-shadow:
2px 2px 0 black,
-1px -1px 0 black,
1px -1px 0 black,
-1px 1px 0 black,
1px 1px 0 black;
}
And finally setting renderType to dom in VsCode User settings.json:
"terminal.integrated.rendererType": "dom",

comment created time in 4 days
PR closed stimulusjs/stimulus
Some frameworks (e.g. Rails and Rack) will HTML escape attributes. This can result in typical action routing attributes to be transformed and broken:
<button data-action="<%= an_escaping_method("click->controller#action") %>"></button>
<%# => <button data-action="click->controller#action"></button> %>
This commit expands the Action Descriptor syntax to account for escaping.
In the case of Rack, there is a small collection of HTML escaped characters:
&escapes into&<escapes into<>escapes into>'escapes into'"escapes into"/escapes into/
Of those characters, the > is the only one currently part of the
Stimulus syntax.
pr closed time in 5 days
pull request commentstimulusjs/stimulus
Account for HTML escaped ActionDescriptor Syntax
Don't think we need an explicit test for this, since it's testing the web platform itself, not Stimulus. 👍
I do think it's interesting to consider how HTML escaping further up the stack interacts with our action descriptor syntax. Technically there's no reason to escape > in a quoted attribute value, but most implementations do it anyway to reduce the attack surface for XSS, or because they don't have context about where the escaped string is used (like in your ERB example). It would be nice if we had better tooling for emitting unescaped >s, but either way it's just an aesthetic thing and ultimately has no bearing on how Stimulus sees the action descriptors.
comment created time in 5 days
pull request commentstimulusjs/stimulus
Account for HTML escaped ActionDescriptor Syntax
The suite passes without the implementation change.
@sstephenson if you don't think this test is a valuable addition to the suite, let's close this PR.
comment created time in 5 days
pull request commentstimulusjs/stimulus
Account for HTML escaped ActionDescriptor Syntax
@sstephenson wow, thanks for pointing that out. I've pushed up a commit to run the test without the implementation changes.
Re-visiting the source error that motivated this change, it appears that I'm doubly escaping the HTML: -> becomes >, and then > becomes &gt;. If that's the true root of this issue, I don't think it's Stimulus' responsibility to account for that.
comment created time in 5 days
pull request commentstimulusjs/stimulus
Account for HTML escaped ActionDescriptor Syntax
Could you clarify how the action attributes are broken? Or is this just an aesthetic issue? This example works fine:
<!DOCTYPE html>
<html>
<head>
<script src="https://unpkg.com/stimulus"></script>
<script>
const app = new Stimulus.Application
app.register("hello", class extends Stimulus.Controller {
greet() {
alert("Hello!")
}
})
app.start()
</script>
</head>
<body>
<button data-controller="hello" data-action="click->hello#greet">Greet</button>
</body>
</html>
comment created time in 5 days
issue commentstimulusjs/stimulus
Alternative CDN: https://www.jsdelivr.com/package/npm/stimulus
comment created time in 5 days
Pull request review commentstimulusjs/stimulus
Account for HTML escaped ActionDescriptor Syntax
export interface ActionDescriptor { } // capture nos.: 12 23 4 43 1 5 56 7 768 9 98-const descriptorPattern = /^((.+?)(@(window|document))?->)?(.+?)(#([^:]+?))(:(.+))?$/+const descriptorPattern = /^((.+?)(@(window|document))?(->|->))?(.+?)(#([^:]+?))(:(.+))?$/
I couldn't regexp myself out of a wet paper bag, and I wonder if this style disrupts the // capture nos.: above.
comment created time in 6 days
pull request commentstimulusjs/stimulus
Account for HTML escaped ActionDescriptor Syntax
As an alternative to this, we could change the frameworks to be less strict and skip the escaping, but slightly expanding the Stimulus syntax feels like a lower risk solution.
What do you think @sstephenson @javan?
comment created time in 6 days
Pull request review commentstimulusjs/stimulus
Account for HTML escaped ActionDescriptor Syntax
export interface ActionDescriptor { } // capture nos.: 12 23 4 43 1 5 56 7 768 9 98-const descriptorPattern = /^((.+?)(@(window|document))?->)?(.+?)(#([^:]+?))(:(.+))?$/+const descriptorPattern = /^((.+?)(@(window|document))?(->|>))?(.+?)(#([^:]+?))(:(.+))?$/
I couldn't regexp myself out of a wet paper bag, and I wonder if this style disrupts the // capture nos.: above.
comment created time in 6 days
PR opened stimulusjs/stimulus
Some frameworks (e.g. Rails and Rack) will HTML escape attributes. This can result in typical action routing attributes to be transformed and broken:
<button data-action="<%= an_escaping_method("input->controller#action")
%>"></button>
<%# => <button data-action="input->controller#action"></button>
This commit expands the Action Descriptor syntax to account for escaping.
In the case of Rack, there is a small collection of HTML escaped characters:
&escapes into&<escapes into<>escapes into>'escapes into'- ``` escapes into `""
/escapes into/
Of those characters, the > is the only one currently part of the
Stimulus syntax.
pr created time in 6 days
issue commenttonsky/FiraCode
Feasibility of dual color font
No idea but font is definitely not the answer. Try making a feature request for windows terminal
comment created time in 6 days
issue commentstimulusjs/stimulus
`connect` not picking up initial values of input elements (browser 'back' button)
I created a library to provide a forms bfcache solution for Turbolinks.
https://github.com/tleish/turbolinks-bfcache-form
comment created time in 6 days
issue closedtonsky/FiraCode
Browser usage seems not to work
I'm trying to add Fira Code to my blog's codeblocks, but it seems not to work.

I'm using nuxt/content for it, so I'm adding the woff2 files to my assets folder and adding it to my .scss
// Fira Code v5
@font-face {
font-family: 'Fira Code';
font-style: normal;
font-weight: 300 700;
font-display: swap;
src: url('~assets/fonts/Fira_Code_v5.2/woff2/FiraCode-VF.woff2') format('woff2-variations');
}
It's being loaded, but it seems to not work

I was hoping to see:

closed time in 6 days
gigioSouzaissue commenttonsky/FiraCode
Browser usage seems not to work
I found the issue, the letter-spacing was different then 0.
Thank you guys for the fast responses and effort to help me!
comment created time in 6 days
issue commenttonsky/FiraCode
Feasibility of dual color font
There is a huge difference from first to second...


Any ideas how to achieve that in windows terminal @tonsky ?
comment created time in 7 days
issue commenttonsky/FiraCode
Feasibility of dual color font
This can be achieved with font rendering, no reason for this to be in the font
comment created time in 7 days
issue closedtonsky/FiraCode
Feasibility of dual color font
4k monitors can display dual color fonts so that when a transparent or translucid background is used, there is no readability penalty, the same strategy used by many subtitle engines. In this regard what about making a dual color FiraCode font?
closed time in 7 days
DanielAtKryptonissue commenttonsky/FiraCode
Feasibility of dual color font
This way, in a completely transparent screen, when the background becomes completely white or completely black, the text can be seen without a problem.
comment created time in 7 days
issue commenttonsky/FiraCode
Feasibility of dual color font
I believe the default should be white text outlined in black for dark translucent backgrounds for example. And black outlined white for bright translucent backgrounds, for example.
For subtitles some countries use yellow instead of white.
comment created time in 7 days
issue commenttonsky/FiraCode
Feasibility of dual color font
What do you mean? What would second color be?
comment created time in 7 days