Skip to content

Conversation

thgrund
Copy link

@thgrund thgrund commented Aug 10, 2025

This will fix the following issues:

General speaking we need to whitelabel chars that are considered as part of a word inside of the mini notation. I added an additional check, that will avoid that the event highlighting crashes because of a wrong tokenization.

@thgrund thgrund changed the title White label minus and dot chars in mini notation [Event Highlighting]: White label minus and dot chars in mini notation Aug 11, 2025
@thgrund thgrund changed the title [Event Highlighting]: White label minus and dot chars in mini notation [Event Highlighting]: White label minus, dot and colon chars in mini notation Aug 13, 2025
Copy link
Collaborator

@ndr-brt ndr-brt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good overall, I'd just suggested two cosmetic comments

Comment on lines 9 to 22
const digitMin = 48;
const digitMax = 57;
// A-Z
const upperCaseMin = 65;
const upperCaseMax = 90;
// a-z
const lowerCaseMin = 97;
const lowerCaseMax = 122;
// .
const dot = 46;
// -
const minus = 45;
// :
const colon = 58;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these const could be kept at the class level, so it will keep the isValidTidalWordChar tidier

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes! what a pity that in js there's the need to prepone the class name on every constant call

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree!

static isQuotationMark(character) {
const code = character.charCodeAt(0);
// "
const quotationMark = 34;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same

Copy link
Collaborator

@ndr-brt ndr-brt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ndr-brt ndr-brt merged commit 1e94c03 into tidalcycles:master Aug 19, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Event highlighting crashes with following code event highlighting: dots not recognized
2 participants