Skip to content

Commit

Permalink
Merge branch 'master' into basic-validation
Browse files Browse the repository at this point in the history
  • Loading branch information
LaChope committed Feb 20, 2024
2 parents e6ede20 + 92636ba commit 248f8c0
Show file tree
Hide file tree
Showing 46 changed files with 33,847 additions and 13,825 deletions.
1 change: 0 additions & 1 deletion .github/workflows/npm-publish-alpha.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ jobs:
node-version: 16
registry-url: https://registry.npmjs.org
- run: npm ci
- run: npm test
- run: npm run build
- run: npm publish --access public --ignore-scripts --tag alpha
env:
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

## 0.7.0 (2023-07-13)

- migration to React v18

### [0.6.4](https://kbss.felk.cvut.cz/git/s-forms/compare/v0.6.3...v0.6.4) (2022-11-06)

### [0.6.3](https://kbss.felk.cvut.cz/git/s-forms/compare/v0.6.2...v0.6.3) (2022-11-04)
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Checkout [live demo using storybook](https://s-forms-kbss.netlify.app).
## Supported features

- Input/Textarea
- Typeahead
- Tree Typeahead
- Datetime picker
- Select
- Checkbox
Expand All @@ -19,7 +19,7 @@ Checkout [live demo using storybook](https://s-forms-kbss.netlify.app).
## Representation in JSON-LD

Semantic form is structure that holds a form (set of questions) as well as its data (set of answers).
A conceptual model of Semantic forms is [questions/answers model](https://kbss.felk.cvut.cz/gitblit/summary/s-forms-model.git).
A conceptual model of Semantic forms is [questions/answers model](https://github.com/kbss-cvut/s-forms-model).
The conceptual model is described in RDF language. This library processes and generates Semantic forms using JSON-LD
format which is JSON compatible serialization of the RDF language.

Expand Down
26 changes: 26 additions & 0 deletions jest-environment-jsdom.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
"use strict";

const { TextEncoder, TextDecoder } = require("util");
const {
default: $JSDOMEnvironment,
TestEnvironment,
} = require("jest-environment-jsdom");

Object.defineProperty(exports, "__esModule", {
value: true,
});

// Using Jest 29, TextEncoder and TextDecoder do not have support, see https://github.com/jsdom/jsdom/issues/2524,
// Solution was found here: https://github.com/jsdom/jsdom/issues/2524#issuecomment-1480930523
class JSDOMEnvironment extends $JSDOMEnvironment {
constructor(...args) {
const { global } = super(...args);
if (!global.TextEncoder) global.TextEncoder = TextEncoder;
if (!global.TextDecoder) global.TextDecoder = TextDecoder;
if (!global.Uint8Array) global.Uint8Array = Uint8Array;
}
}

exports.default = JSDOMEnvironment;
exports.TestEnvironment =
TestEnvironment === $JSDOMEnvironment ? JSDOMEnvironment : TestEnvironment;
6 changes: 4 additions & 2 deletions jest.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,10 @@ module.exports = {
moduleFileExtensions: ["js", "jsx", "json", "ts", "tsx"],
setupFiles: ["<rootDir>/test/setup.js"],
transformIgnorePatterns: ["[/\\\\]node_modules[/\\\\].+\\.(ts|tsx)$"],
testEnvironment: "jsdom",
testURL: "http://localhost",
testEnvironment: "./jest-environment-jsdom.cjs",
testEnvironmentOptions: {
url: "http://localhost",
},
transform: {
"^.+\\.(js|jsx|ts|tsx)$": "babel-jest",
},
Expand Down
Loading

0 comments on commit 248f8c0

Please sign in to comment.