Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
96 changes: 12 additions & 84 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,87 +1,15 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file

version: 2
updates:
- package-ecosystem: npm
directory: '/'
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: weekly
day: saturday
time: '07:07'
timezone: America/Los_Angeles
open-pull-requests-limit: 10
versioning-strategy: increase
ignore:
- dependency-name: husky
versions:
- '>= 6.a, < 7'
- dependency-name: postcss
versions:
- 8.2.10
- 8.2.12
- 8.2.6
- 8.2.7
- 8.2.8
- 8.2.9
- dependency-name: '@types/jest'
versions:
- 26.0.21
- 26.0.22
- dependency-name: eslint
versions:
- 7.22.0
- 7.23.0
- 7.24.0
- dependency-name: '@typescript-eslint/eslint-plugin'
versions:
- 4.14.1
- 4.15.0
- 4.15.1
- 4.15.2
- 4.16.1
- 4.17.0
- 4.18.0
- 4.19.0
- 4.20.0
- 4.21.0
- 4.22.0
- dependency-name: husky
versions:
- 5.0.9
- 5.1.1
- 5.1.3
- 5.2.0
- dependency-name: typescript
versions:
- 4.1.5
- 4.2.2
- 4.2.3
- dependency-name: ts-jest
versions:
- 26.5.0
- 26.5.1
- 26.5.2
- 26.5.3
- dependency-name: check-node-version
versions:
- 4.1.0
- dependency-name: lint-staged
versions:
- 10.5.4
- dependency-name: '@types/node'
versions:
- 14.14.22
- 14.14.27
- dependency-name: autoprefixer
versions:
- 10.2.3
- 10.2.4
- dependency-name: '@typescript-eslint/parser'
versions:
- 4.14.1
- 4.18.0
- 4.19.0
- 4.20.0
- 4.21.0
- 4.22.0
- dependency-name: '@typescript-eslint/typescript-estree'
versions:
- 4.14.1
interval: "daily"
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "daily"
4 changes: 2 additions & 2 deletions .github/workflows/playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ jobs:
timeout-minutes: 60
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
- name: Install dependencies
Expand Down
29 changes: 29 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Publish package to GitHub Packages
on:
release:
types: [created]
workflow_dispatch:

permissions:
contents: read
packages: write

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
# Setup .npmrc file to publish to GitHub Packages
- uses: actions/setup-node@v4
with:
node-version: '22.x'
registry-url: 'https://npm.pkg.github.com'
# Defaults to the user or organization that owns the workflow file
scope: '@kedyou'
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4 changes: 2 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ jobs:
timeout-minutes: 20
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
- name: Install dependencies
Expand Down
5 changes: 4 additions & 1 deletion .npmrc
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
loglevel="warn"
//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}
@kedyou:registry=https://npm.pkg.github.com
always-auth=true
loglevel="warn"
42 changes: 41 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<img alt="math live" src="assets/mathlive-1.png?raw=true">
</div>

<h3>The <strong>MathLive</strong> mathfield</h3>
<h3><strong>Kedyou's fork of MathLive</strong></h3>
<h1>A Web Component for Math Input</h1>

[![Maintenance](https://img.shields.io/maintenance/yes/2025.svg)]()
Expand Down Expand Up @@ -124,3 +124,43 @@ contribution.
## 📃 License

This project is licensed under the [MIT License](LICENSE.txt).

## Kedyou

The Kedyou modification of MathLive allows users to type multi-lined math
quickly and easily, simplifying the inputs to create and modify aligned
environments.

Update with the latest changes from arnog:

```sh
# Add the remote, call it "upstream":
git remote add upstream https://github.com/arnog/mathlive/
# Fetch all the branches of that remote into remote-tracking branches
git fetch upstream
# Make sure that you're on your master branch:
git checkout master
# Rewrite your master branch so that any commits of yours that
# aren't already in upstream/master are replayed on top of that
# other branch:
git rebase upstream/master
# After finishing rebase/merging changes, force push
git push --force
```

### Local testing

To test the MathLive in Kedyou before publishing, use `pnpm link --global`:

```sh
# In mathlive repo
pnpm link --global
# In the kedyou-frontend repo
pnpm link --global @kedyou/mathlive
```

#### **`sites/frontend/package.json`**
```diff
-"@kedyou/mathlive": "^0.98.6"
+"@kedyou/mathlive": "link:^0.98.6"
```
2 changes: 1 addition & 1 deletion css/mathfield.less
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
/* This attribute is necessary to work around a Firefox issue where
where clicking multiple times on the border leads to a focused mathfield that cannot be edited until focus is lost and regained (also fixes the multiple cursor issue on firefox that can occur with the same sequence of events).
*/
pointer-events: auto;
pointer-events: var(--pointer-events, auto);

/* Prevent the browser from trying to interpret touch gestures in the field */
/* "Disabling double-tap to zoom removes the need for browsers to
Expand Down
2 changes: 1 addition & 1 deletion css/suggestion-popover.less
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
text-align: center;
border-radius: 8px;
position: fixed;
z-index: var(--_suggestion-zindex);
z-index: var(--_suggestion-zindex, 99);

display: none;
flex-direction: column;
Expand Down
7 changes: 4 additions & 3 deletions css/virtual-keyboard.less
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,6 @@
--_keycap-max-width: var(--keycap-max-width, 100px);
--_keycap-gap: var(--keycap-gap, 8px);

--_keycap-font-size: var(--keycap-font-size, ~'clamp(16px, 4cqw, 24px)');
--_keycap-small-font-size: var(
--keycap-small-font-size,
calc(var(--keycap-font-size) * 0.8)
Expand Down Expand Up @@ -426,7 +425,8 @@ body > .ML__keyboard.is-visible.animate > .MLK__backdrop {
}

.big-op {
font-size: calc(1.25 * var(--_keycap-font-size));
font-size: calc(1.25 * var(--keycap-font-size, ~"clamp(16px, 4vw, 24px)"));
font-size: calc(1.25 * var(--keycap-font-size, ~"clamp(16px, 4cqw, 24px)"));
}

.small {
Expand Down Expand Up @@ -563,7 +563,8 @@ body > .ML__keyboard.is-visible.animate > .MLK__backdrop {

color: var(--_keycap-text);
fill: currentColor;
font-size: var(--_keycap-font-size);
font-size: var(--keycap-font-size, ~"clamp(16px, 4vw, 24px)");
font-size: var(--keycap-font-size, ~"clamp(16px, 4cqw, 24px)");
background: var(--_keycap-background);
border: 1px solid var(--_keycap-border);
border-bottom-color: var(--_keycap-border-bottom);
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 4 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "mathlive",
"name": "@kedyou/mathlive",
"version": "0.106.0",
"description": "A web component for math input",
"license": "MIT",
Expand Down Expand Up @@ -31,10 +31,6 @@
"require": "./mathlive.js"
}
},
"node": {
"types": "./types/mathlive-ssr.d.ts",
"import": "./mathlive-ssr.min.mjs"
},
"default": {
"types": "./types/mathlive.d.ts",
"import": "./mathlive.min.mjs",
Expand All @@ -48,9 +44,8 @@
},
"repository": {
"type": "git",
"url": "git+https://github.com/arnog/mathlive.git"
"url": "git+https://github.com/kedyou/mathlive.git"
},
"bugs": "https://github.com/arnog/mathlive/issues/",
"scripts": {
"doc": "bash ./scripts/update-docs.sh",
"build": "bash ./scripts/build.sh",
Expand Down Expand Up @@ -171,5 +166,6 @@
"mathjax",
"katex",
"mathquill"
]
],
"homepage": "https://github.com/kedyou/mathlive#readme"
}
1 change: 1 addition & 0 deletions scripts/start.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ context({
entryPoints: [
'./test/style.css',
'./test/smoke/index.html',
'./test/printing/index.html',
'./test/virtual-keyboard/index.html',
'./test/mathfield-states/index.html',
'./test/prompts/index.html',
Expand Down
47 changes: 47 additions & 0 deletions src/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -3756,6 +3756,16 @@ addRowBefore: (model) => boolean;

<MemberCard>

##### Commands.createAlignedEnvironment()

```ts
createAlignedEnvironment: (model) => boolean;
```

</MemberCard>

<MemberCard>

##### Commands.removeColumn()

```ts
Expand Down Expand Up @@ -5045,6 +5055,22 @@ hide(options?): void

<MemberCard>

##### VirtualKeyboardInterface.manualClose()

```ts
manualClose(options?): void
```

###### options?

###### animate

`boolean`

</MemberCard>

<MemberCard>

##### VirtualKeyboardInterface.setKeycap()

```ts
Expand Down Expand Up @@ -5759,6 +5785,7 @@ type VirtualKeyboardMessageAction =
| "execute-command"
| "show"
| "hide"
| "manual-close"
| "update-setting"
| "update-toolbar"
| "synchronize-proxy"
Expand Down Expand Up @@ -6463,6 +6490,26 @@ LaTeX global registers override.

<MemberCard>

### DEFAULT\_KEYBOARD\_TOGGLE\_GLYPH

```ts
const DEFAULT_KEYBOARD_TOGGLE_GLYPH: string;
```

</MemberCard>

<MemberCard>

### MENU\_GLYPH

```ts
const MENU_GLYPH: string;
```

</MemberCard>

<MemberCard>

### version

```ts
Expand Down
Loading
Loading