Security News
NIST Misses 2024 Deadline to Clear NVD Backlog
NIST has failed to meet its self-imposed deadline of clearing the NVD's backlog by the end of the fiscal year. Meanwhile, CVE's awaiting analysis have increased by 33% since June.
mobile-navigation-controller
Advanced tools
Navigator for JavaScript mobile app, This will help you to manage your pages history in the app and change pages with animation.
It's manager for your pages like mobile app.
import Navigator from 'mobile-navigation-controller';
<Navigator onRef={ref => (this.navigatorRef = ref)} >
<MyHomePage key="home" levelPage={0} />
<AboutPage key="about"
levelPage={1}
/>
</Navigator>
Note: prop levelPage
important to manage the returs (from back button) in the structure of a tree
To change page you get the ref and do:
this.navigatorRef.changePage("about");
the option to changePage it's:
this.navigatorRef.changePage(
goToPage //Required
,{options}// Not requred
);
options => { animationIn:string // have defult
, animationOut:string // have defult
, timeAnimationInMS:integer // defult=250(ms)
, callbackFun:function
, props:{}
}
*animationIn
and animationOut
need name animate from here
*the animate.css includ in this package
prop | type | required | defult | node |
---|---|---|---|---|
onRef | required | - | onRef={ref => (this.navigatorRef = ref)} | |
key | string | required | - | |
height | string or integer | optional | "100%" | |
onChangePage | function | optional | - | (nowPageKey,levelAction) => { ... } |
beforChangePage | function | optional | - | (goToPageKey,levelAction) => { ... } |
homePageKey | string | optional | The key of the first child | (nowPageKey,levelAction) => { ... } |
changeRoute | boolean | optional | true (on cordova native platforms => false) | Determines whether to change the URL to the component key |
prop | type | required | defult | node |
---|---|---|---|---|
levelPage | integer | required | - | important! |
backgroundColor | string | optional | #fff | |
height | string or integer | optional | "100%" | |
backOnSwipeRight | boolean | optional | false | May be problematic with css "padding-left" |
alwaysLive | boolean | optional | false | Don't kill the child. Life is always in the background |
const nowPage= this.navigatorRef.nowPage;
const historyPages= this.navigatorRef.historyPages();
const listLevelPages= this.navigatorRef.listLevelPages();
this.navigatorRef.back();
or
this.navigatorRef.back({options...});
options => { animationIn:integer // have defult , animationOut:string // have defult , timeAnimationInMS:integer // defult=250(ms) , callbackFun:function , props:{...} }
const navigator_busy= this.navigatorRef.busy;
*busy return boolean
Credit:
Arik Wald
Credit animated:
animate.css -https://daneden.github.io/animate.css/
FAQs
Navigator for JavaScript mobile app, This will help you to manage your pages history in the app and change pages with animation.
The npm package mobile-navigation-controller receives a total of 7 weekly downloads. As such, mobile-navigation-controller popularity was classified as not popular.
We found that mobile-navigation-controller demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
NIST has failed to meet its self-imposed deadline of clearing the NVD's backlog by the end of the fiscal year. Meanwhile, CVE's awaiting analysis have increased by 33% since June.
Security News
Cloudflare has launched a setup wizard allowing users to easily create and manage a security.txt file for vulnerability disclosure on their websites.
Security News
The Socket Research team breaks down a malicious npm package targeting the legitimate DOMPurify library. It uses obfuscated code to hide that it is exfiltrating browser and crypto wallet data.