8000 feat: extract wasm tar in /jans-tarp folder by duttarnab · Pull Request #10689 · JanssenProject/jans · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat: extract wasm tar in /jans-tarp folder #10689

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jan 20, 2025
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
6 changes: 3 additions & 3 deletions .github/workflows/build-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -334,10 +334,10 @@ jobs:
TAG="0.0.0"
fi
wget https://github.com/${{ github.repository }}/releases/download/"${VER}"/cedarling_wasm_"${TAG}"_pkg.tar.gz -O cedarling_wasm.tar.gz
mkdir -p src/wasm
tar -xvf cedarling_wasm.tar.gz -C src/wasm
mkdir -p wasm
tar -xvf cedarling_wasm.tar.gz -C wasm
rm cedarling_wasm.tar.gz
ls src/wasm
ls wasm
# END Get the latest cedarling wasm package
npm install
npm run build
Expand Down
4 changes: 2 additions & 2 deletions demos/jans-tarp/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jans-tarp",
"version": "0.0.0-nightly",
"version": "0.0.0",
"description": "Relying Party tool in form of a Chrome Extension.",
"main": "index.js",
"license": "Apache",
Expand Down Expand Up @@ -50,6 +50,6 @@
"react-spinner-overlay": "^0.1.33",
"styled-components": "^6.1.0",
"uuid": "^9.0.0",
"wasm": "file:src/wasm"
"wasm": "file:wasm"
}
}
5 changes: 3 additions & 2 deletions demos/jans-tarp/src/options/userDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import AccordionDetails from '@mui/material/AccordionDetails';
import Typography from '@mui/material/Typography';
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';

import __wbg_init, { init, Cedarling, AuthorizeResult } from "wasm";
import __wbg_init, { init, Cedarling, AuthorizeResult } from 'wasm';

const UserDetails = ({ data, notifyOnDataChange }) => {
const [loading, setLoading] = useState(false);
Expand Down Expand Up @@ -61,9 +61,10 @@ const UserDetails = ({ data, notifyOnDataChange }) => {
await __wbg_init();
instance = await init(!isEmpty(cedarlingConfig?.cedarlingConfig) ? cedarlingConfig?.cedarlingConfig[0] : undefined);
let result: AuthorizeResult = await instance.authorize(reqObj);
let logs = await instance.pop_logs();
setAuthzResult(result.json_string())
console.log("result:", result);
let logs = await instance.pop_logs();
logs.push(await instance.pop_logs());
if (logs.length != 0) {
let pretty_logs = logs.map(log => JSON.stringify(log, null, 2));
setAuthzLogs(pretty_logs.toString());
Expand Down
2 changes: 1 addition & 1 deletion demos/jans-tarp/src/static/chrome/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"manifest_version": 3,
"name": "jans-tarp",
"version": "0.0.0-nightly",
"version": "0.0.0",
"version_name": "nightly",
"description": "Relying Party tool in form of a Chrome Extension. Please note that the manifest version field should be one to four dot-separated integers identifying the version of this extension. The descriptive version string can be stated in the `version_name` field. For more details see https://developer.chrome.com/docs/extensions/reference/manifest/version.",
"icons": {
Expand Down
2 changes: 1 addition & 1 deletion demos/jans-tarp/src/static/firefox/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"manifest_version": 3,
"name": "jans-tarp",
"version": "0.0.0-nightly",
"version": "0.0.0",
"description": "Relying Party tool in form of a Firefox Extension.",
"icons": {
"16": "icon.png",
Expand Down
0