-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #357 from lblod/feat/rdfa-editing-ui
Plugin support for reworked RDFa parsing/serializing and UI/UX
- Loading branch information
Showing
111 changed files
with
21,938 additions
and
39,985 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@lblod/ember-rdfa-editor-lblod-plugins': patch | ||
--- | ||
|
||
Remove `@import "ember-appuniversum"` statements from plugin sass modules in order to prevent style overrding. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
'@lblod/ember-rdfa-editor-lblod-plugins': minor | ||
--- | ||
|
||
- Addition of the `say-template-comment` class to the static version of template comments. | ||
- Addition of some extra styles to the `say-template-comment` class. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--- | ||
"@lblod/ember-rdfa-editor-lblod-plugins": major | ||
--- | ||
|
||
### RDFa aware editing | ||
|
||
This release adapts plugins | ||
to [RDFa (RDF in Attributes)](https://github.com/lblod/ember-rdfa-editor/blob/9c32a9dea0da13df4092c39d9a092ba0803a3f42/README.md#experimental-a-new-approach-to-handle-rdfa-in-documents) | ||
aware editing, based on the changes in `ember-rdfa-editor` | ||
version [9.6.0](https://github.com/lblod/ember-rdfa-editor/releases/tag/v9.6.0) | ||
|
||
#### N.B. This release is not compatible with `ember-rdfa-editor` configurations that don't use ` rdfaAware` features, see [editor documentation](https://github.com/lblod/ember-rdfa-editor/blob/9c32a9dea0da13df4092c39d9a092ba0803a3f42/README.md#experimental-a-new-approach-to-handle-rdfa-in-documents) for more. | ||
|
||
#### Changes | ||
|
||
* Plugins now use RDFa aware specs when rendering to HTML, and they also expect RDFa aware specs when parsing from HTML. | ||
* Introduces RDFa aware version of `snippet-plugin`, that allows to record allowed snippet list IDs on a resource node level in the document. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@lblod/ember-rdfa-editor-lblod-plugins': patch | ||
--- | ||
|
||
GN-4650: Fix behavior of "Insert snippet" button |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@lblod/ember-rdfa-editor-lblod-plugins": patch | ||
--- | ||
|
||
article-structure-plugin: Make `setStartNumber` and `getStartNumber` properties optional |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@lblod/ember-rdfa-editor-lblod-plugins': minor | ||
--- | ||
|
||
GN-4650: Snippet selection placeholder in template |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@lblod/ember-rdfa-editor-lblod-plugins': minor | ||
--- | ||
|
||
Add helper function to help with locale selection and add translation note to readme |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@lblod/ember-rdfa-editor-lblod-plugins': patch | ||
--- | ||
|
||
Fix template-comment padding |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@lblod/ember-rdfa-editor-lblod-plugins": minor | ||
--- | ||
|
||
Ensure that variables are node-selected/focused after insertion |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@lblod/ember-rdfa-editor-lblod-plugins": patch | ||
--- | ||
|
||
Allow to insert structure even if insertion range does not have RDFA attributes. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
steps: | ||
install: | ||
image: node:20-slim | ||
commands: | ||
- corepack enable | ||
- pnpm i --frozen-lockfile | ||
version: | ||
image: node:20-slim | ||
commands: | ||
- npm version --no-git-tag-version $(npm pkg get version | sed 's/"//g')-dev.${CI_COMMIT_SHA} | ||
release: | ||
image: plugins/npm | ||
settings: | ||
token: | ||
from_secret: npm_access_token | ||
tag: dev | ||
when: | ||
- event: push |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
steps: | ||
install: | ||
image: node:20-slim | ||
commands: | ||
- corepack enable | ||
- pnpm i --frozen-lockfile | ||
release: | ||
image: plugins/npm | ||
settings: | ||
token: | ||
from_secret: npm_access_token | ||
push-tagged-build: | ||
image: plugins/docker | ||
settings: | ||
repo: lblod/ember-rdfa-editor-lblod-plugins | ||
tags: '${CI_COMMIT_TAG##v}' | ||
purge: true | ||
secrets: [docker_username, docker_password] | ||
when: | ||
event: tag | ||
ref: refs/tags/v* |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
steps: | ||
install: | ||
image: node:20-slim | ||
commands: | ||
- corepack enable | ||
- pnpm i --frozen-lockfile | ||
lint-js: | ||
image: node:20-slim | ||
group: lint | ||
commands: | ||
- corepack enable | ||
- pnpm lint:js | ||
lint-hbs: | ||
image: node:20-slim | ||
group: lint | ||
commands: | ||
- corepack enable | ||
- pnpm lint:hbs | ||
test: | ||
image: danlynn/ember-cli:4.12.1 | ||
commands: | ||
- corepack enable | ||
- pnpm test:ember | ||
precompile: | ||
image: node:20-slim | ||
commands: | ||
- corepack enable | ||
- pnpm prepack | ||
when: | ||
- evaluate: 'CI_PIPELINE_EVENT == "pull_request" && not (CI_COMMIT_PULL_REQUEST_LABELS contains "dependabot")' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,14 @@ | ||
FROM madnificent/ember:4.12.1-node_18 as builder | ||
FROM node:20-slim AS builder | ||
|
||
LABEL maintainer="[email protected]" | ||
|
||
RUN corepack enable | ||
RUN corepack prepare pnpm@latest-8 --activate | ||
WORKDIR /app | ||
COPY package.json package-lock.json ./ | ||
RUN npm ci | ||
COPY package.json pnpm-lock.yaml ./ | ||
RUN pnpm i --frozen-lockfile | ||
COPY . . | ||
RUN ember build -prod | ||
RUN pnpm build | ||
|
||
FROM semtech/static-file-service:0.2.0 | ||
COPY --from=builder /app/dist /data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default as replaceSelectionWithAndSelectNode } from './replace-selection-and-select-node'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import { Command, NodeSelection, PNode } from '@lblod/ember-rdfa-editor'; | ||
|
||
const replaceSelectionWithAndSelectNode = (node: PNode): Command => { | ||
return (state, dispatch) => { | ||
if (!node.type.spec.selectable) { | ||
return false; | ||
} | ||
|
||
if (dispatch) { | ||
const tr = state.tr; | ||
tr.replaceSelectionWith(node); | ||
if (tr.selection.$anchor.nodeBefore) { | ||
const resolvedPos = tr.doc.resolve( | ||
tr.selection.anchor - tr.selection.$anchor.nodeBefore?.nodeSize, | ||
); | ||
tr.setSelection(new NodeSelection(resolvedPos)); | ||
} | ||
dispatch(tr); | ||
} | ||
return true; | ||
}; | ||
}; | ||
|
||
export default replaceSelectionWithAndSelectNode; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.