{"id":15674424,"url":"https://github.com/sinedied/ngx-foldable","last_synced_at":"2025-08-25T21:15:17.590Z","repository":{"id":49191744,"uuid":"294428676","full_name":"sinedied/ngx-foldable","owner":"sinedied","description":"Angular library to help your build dual-screen experiences for foldable or dual-screen devices","archived":false,"fork":false,"pushed_at":"2023-04-07T07:34:46.000Z","size":4616,"stargazers_count":14,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-08-20T07:42:47.980Z","etag":null,"topics":["angular","components","duo","experience","foldable","hacktoberfest","library","multiscreen","surface"],"latest_commit_sha":null,"homepage":"https://sinedied.github.io/ngx-foldable/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sinedied.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-09-10T14:09:54.000Z","updated_at":"2023-09-25T13:14:40.000Z","dependencies_parsed_at":"2024-10-06T21:51:00.475Z","dependency_job_id":"309a66e6-592d-4894-8f2e-43741261157b","html_url":"https://github.com/sinedied/ngx-foldable","commit_stats":null,"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"purl":"pkg:github/sinedied/ngx-foldable","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sinedied%2Fngx-foldable","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sinedied%2Fngx-foldable/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sinedied%2Fngx-foldable/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sinedied%2Fngx-foldable/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sinedied","download_url":"https://codeload.github.com/sinedied/ngx-foldable/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sinedied%2Fngx-foldable/sbom","scorecard":{"id":826974,"data":{"date":"2025-08-11","repo":{"name":"github.com/sinedied/ngx-foldable","commit":"8c1095f2c9e346ddf3b816611282edf5e7a9a57d"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.5,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Code-Review","score":0,"reason":"Found 0/25 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/build.yml:1","Warn: no topLevel permission defined: .github/workflows/release.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Pinned-Dependencies","score":4,"reason":"dependency not pinned by hash detected -- score normalized to 4","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/sinedied/ngx-foldable/build.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/sinedied/ngx-foldable/build.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/sinedied/ngx-foldable/release.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/sinedied/ngx-foldable/release.yml/main?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:34: update your workflow using https://app.stepsecurity.io/secureworkflow/sinedied/ngx-foldable/release.yml/main?enable=pin","Warn: npmCommand not pinned by hash: .github/workflows/build.yml:26","Info:   0 out of   4 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned","Info:   2 out of   3 npmCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact 5.0.0 not signed: https://api.github.com/repos/sinedied/ngx-foldable/releases/84471169","Warn: release artifact 4.0.0 not signed: https://api.github.com/repos/sinedied/ngx-foldable/releases/68561802","Warn: release artifact 3.1.0 not signed: https://api.github.com/repos/sinedied/ngx-foldable/releases/68560229","Warn: release artifact 3.0.0 not signed: https://api.github.com/repos/sinedied/ngx-foldable/releases/54059669","Warn: release artifact 2.0.0 not signed: https://api.github.com/repos/sinedied/ngx-foldable/releases/53874654","Warn: release artifact 5.0.0 does not have provenance: https://api.github.com/repos/sinedied/ngx-foldable/releases/84471169","Warn: release artifact 4.0.0 does not have provenance: https://api.github.com/repos/sinedied/ngx-foldable/releases/68561802","Warn: release artifact 3.1.0 does not have provenance: https://api.github.com/repos/sinedied/ngx-foldable/releases/68560229","Warn: release artifact 3.0.0 does not have provenance: https://api.github.com/repos/sinedied/ngx-foldable/releases/54059669","Warn: release artifact 2.0.0 does not have provenance: https://api.github.com/repos/sinedied/ngx-foldable/releases/53874654"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 6 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"45 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-h5c3-5r3r-rr8q","Warn: Project is vulnerable to: GHSA-rmvr-2pp2-xj38","Warn: Project is vulnerable to: GHSA-xx4v-prfh-6cgc","Warn: Project is vulnerable to: GHSA-qwcr-r2fm-qrc7","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-xwcq-pm8m-c4vf","Warn: Project is vulnerable to: GHSA-q9mw-68c2-j6m5","Warn: Project is vulnerable to: GHSA-4gmj-3p3h-gm8h","Warn: Project is vulnerable to: GHSA-67mh-4wv8-2f99","Warn: Project is vulnerable to: GHSA-rv95-896h-c2vc","Warn: Project is vulnerable to: GHSA-qw6h-vgh9-j6wx","Warn: Project is vulnerable to: GHSA-jchw-25xp-jwwc","Warn: Project is vulnerable to: GHSA-cxjh-pqwp-8mfp","Warn: Project is vulnerable to: GHSA-c7qv-q95q-8v27","Warn: Project is vulnerable to: GHSA-4www-5p9h-95mh","Warn: Project is vulnerable to: GHSA-9gqv-wp59-fq42","Warn: Project is vulnerable to: GHSA-78xj-cgh5-2h22","Warn: Project is vulnerable to: GHSA-2p57-rm9w-gvfp","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55","Warn: Project is vulnerable to: GHSA-76c9-3jph-rj3q","Warn: Project is vulnerable to: GHSA-9wv6-86v2-598j","Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w","Warn: Project is vulnerable to: GHSA-wgrm-67xf-hhpq","Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j","Warn: Project is vulnerable to: GHSA-gcx4-mw62-g8wm","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg","Warn: Project is vulnerable to: GHSA-76p7-773f-r4q5","Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p","Warn: Project is vulnerable to: GHSA-25hc-qcg6-38wj","Warn: Project is vulnerable to: GHSA-cqmj-92xf-r6r9","Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-4vvj-4cpr-p986","Warn: Project is vulnerable to: GHSA-wr3j-pwj9-hqq6","Warn: Project is vulnerable to: GHSA-4v9v-hfq4-rm2v","Warn: Project is vulnerable to: GHSA-9jgg-88mc-972h","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-23T16:48:12.897Z","repository_id":49191744,"created_at":"2025-08-23T16:48:12.897Z","updated_at":"2025-08-23T16:48:12.897Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272132340,"owners_count":24879102,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-25T02:00:12.092Z","response_time":1107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["angular","components","duo","experience","foldable","hacktoberfest","library","multiscreen","surface"],"created_at":"2024-10-03T15:44:28.250Z","updated_at":"2025-08-25T21:15:17.554Z","avatar_url":"https://github.com/sinedied.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 📖 ngx-foldable\n\n[![NPM version](https://img.shields.io/npm/v/ngx-foldable.svg)](https://www.npmjs.com/package/ngx-foldable)\n![Node version](https://img.shields.io/node/v/ngx-foldable.svg)\n![Angular version](https://img.shields.io/badge/angular-%3E%3D15-dd0031?logo=Angular)\n[![Build Status](https://github.com/sinedied/ngx-foldable/workflows/build/badge.svg)](https://github.com/sinedied/ngx-foldable/actions)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)\n\n\u003e ngx-foldable is a set of components and services to help you build dual-screen experiences for foldable or dual-screen devices, such as the [Surface Duo](https://docs.microsoft.com/dual-screen/web/?WT.mc_id=javascript-9776-yolasors)\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./demo.png\"\u003e\n\u003cp\u003e\n\nSee the [live demo](https://sinedied.github.io/ngx-foldable/demo/) or read the [full documentation](https://sinedied.github.io/ngx-foldable/).\n\n## How to test on your browser\n\nThe dual-screen emulation feature requires latest Microsoft Edge or Google Chrome versions (\u003e= 97).\n\nIf you have older browser versions, you need to enable experimental flags.\nFollow [the instructions here](https://devblogs.microsoft.com/surface-duo/build-and-test-dual-screen-web-apps/?WT.mc_id=javascript-9776-yolasors#build-and-test-on-the-desktop) to setup your browser for dual-screen emulation.\n\n## Library usage\n\nCheck out the [demo](./projects/demo/src/app) source code to see an example usage of the library.\n\nAdd the library to your Angular project:\n\n```sh\nnpm install ngx-foldable\n```\n\nImport the library in your app:\n\n```ts\nimport { FoldableModule } from 'ngx-foldable';\n...\n\n@NgModule({\n  ...\n  imports: [\n    FoldableModule\n    ...\n  ],\n  ...\n})\nexport class AppModule { }\n```\n\nUse the provided `fdSplitLayout`, `fdWindow` and `fdIfSpan` directives to build your layout:\n\n```html\n\u003c!--\n  SplitLayout supports: flex, grid or absolute\n  Styling is only added when a multi screen mode is detected.\n--\u003e\n\u003cdiv fdSplitLayout=\"grid\"\u003e\n\n  \u003c!-- Assign to first window segment --\u003e\n  \u003csection fdWindow=\"0\"\u003e\n    This will be displayed on the first window segment of a multi screen or single screen device.\n    \n    \u003cp *fdIfSpan=\"'none'; else alt\"\u003eThis is only visible on a single screen device.\u003c/p\u003e\n    \u003cng-template #alt\u003e\u003cp\u003eThis is only visible on a multi screen device.\u003c/p\u003e\u003c/ng-template\u003e\n  \u003c/section\u003e\n\n  \u003c!-- Assign to second window segment --\u003e\n  \u003csection fdWindow=\"1\"\u003e\n    This will be displayed on the second window segment of a multi screen device.\n\n    \u003cp *fdIfSpan=\"'multi'\"\u003eThis is only visible on multi screen device, regardless of the orientation.\u003c/p\u003e\n    \u003cp *fdIfSpan=\"'dual-vertical'\"\u003eThis is only visible on dual vertical viewports.\u003c/p\u003e\n    \u003cp *fdIfSpan=\"'dual-horizontal'\"\u003eThis is only visible on dual horizontal viewports.\u003c/p\u003e\n  \u003c/section\u003e\n\u003c/div\u003e\n```\n\nUsing the `ScreenContext` service, you can also receive updates when the screen context changes:\n\n```typescript\nimport { ScreenContext } from 'ngx-foldable';\n...\nexport class AppComponent {\n  constructor(private screenContext: ScreenContext) {\n    this.screenContext\n      .asObservable()\n      .subscribe((context) =\u003e {\n        console.log('Screen context changed:', context);\n      });\n  }\n}\n```\n\nYou can read the full documentation [here](https://sinedied.github.io/ngx-foldable/).\n\n## Contributing\n\nYou're welcome to contribute to this project!\nMake sure you have read the [code of conduct](./CODE_OF_CONDUCT) before posting an issue or a pull request.\n\nFollow these steps to run this project locally:\n\n1. Clone the repository on your machine\n2. Run `npm install` to install packages\n3. Run `npm start` to start the dev server with the demo app\n\nYou can then start making modifications on the library or demo app code.\n\n## Related work\n\n- [Surface Duo Photo Gallery](https://github.com/sinedied/surface-duo-photo-gallery): Angular re-implementation of the [Surface Duo Photo Gallery sample](https://github.com/foldable-devices/demos/tree/master/photo-gallery) using this library\n- [react-foldable](https://github.com/aaronpowell/react-foldable): a similar library built for React\n- [foldable-devices/demos](https://github.com/foldable-devices/demos): web demos for foldables devices.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsinedied%2Fngx-foldable","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsinedied%2Fngx-foldable","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsinedied%2Fngx-foldable/lists"}