Bike 2.0 (Preview 275)

  • Added setting to disable animations in Low Power Mode
  • Fixed paste crash when inserting empty text
  • Fixed link button being unclickable due to style
  • Fixed hang when closing document with active filter
  • Improved breadcrumb trimming to respect word boundaries

Extensions

  • Added JSRowRun bridge so the run:: axis works from JS extensions
  • Fixed parent:: axis returning grandparent when evaluated from a run

Download:

2 Likes

for the non-reponsive folding triangle bug, i still occasionally run into it, and i have the logs all activated. if i run into the bug again, what should i do? copy and paste the logs here?

Right after it happens switch to the logs window, select all log entries, copy, and paste into an email or this forum. Truthfully, I’m not all that hopeful that the logs will point to the problem, but it’s worth a try.

Also, try to review in your mind when it does happen… what is the sequence of actions that is causing this? If you can give me steps to reproduce the problem myself then I’m sure I can fix.

1 Like

What are your thoughts about allowing the URL value of a link, in Bike, to consist simply of the number sign (#) followed by a fragment identifier (unique row id) ?

We can do this on web pages, where RFC 3986 presents it as an assumption that the referenced id is in the same document.

Section 4.4. Same-Document Reference

I was able to achieve this via custom styling in 274, while link decorations were in a different z-plane, but since that was fixed for 275, my draft style code still enables same-document jumps to a bare #identifier reference if I click on blued text, but a click on the link decoration icon now triggers Bike’s core URL opening logic, and the message:


What seems like a sensible approach here ? Should my styling code

Expand disclosure triangle to view JS source
import { Color, defineEditorStyleModifier } from 'bike/style'


defineEditorStyleModifier('footnote-jumper', 'Internal Link Jumper')
  .layer('run-formatting', (_, run) => {

    // Outline path matching runs that have an 
    // 'a' (link) attribute starting with a hash (#).
    run('.@a beginswith "#"', (_, runStyle) => {

      runStyle.color = Color.systemBlue();
      runStyle.underline.single = true;


      runStyle.decoration('footnote-click-target', (decoration, layout) => {
        decoration.width = layout.width;
        decoration.height = layout.height;

        // Route clicks to registered command
        decoration.commandName = 'pandoc:jump-to-footnote';

        decoration.zPosition = 10;
      });
    });
  });

find some way of competing for z-axis priority,
or might it, perhaps, be possible to allow Bike’s Open Link logic to treat

href="#row_identifier"

as a synonym of

href="bike://this_doc/row_identifier"

in the pattern of RFC 3986, Section 4.4?