1.2.0 • Published 5 years ago
@time-with/modal v1.2.0
Timewith Modal
Timewith Modal
Install
With npm do:
$ npm install @time-with/modal
or
$ yarn add @time-with/modal
Setup
Add the module to the root Router of the React layout
import TWModal from '@time-with/modal'
render() {
return (
<Router>
<div id='layout-root'>
<TWModal />
// ...
Import the reducer to your reducers combiner
import { modalReducer } from '@time-with/modal';
export default combineReducers({
modalReducer,
...other reducers
});
Usage
import { showModal } from '@time-with/modal';
@connect(
null,
dispatch => ({
actions: bindActionCreators({
showModal,
}, dispatch)
})
)
this.props.actions.showModal({
title: 'Are you sure?',
description: 'By deleting your location, all associated fees and availability slots will be lost.',
showButtonA: true,
showButtonB: true,
buttonACustomHandler: this.someHandler,
buttonACustomHandlerParameters: someParameter,
});
License
MIT
1.2.0
5 years ago
1.1.2
5 years ago
1.1.14
5 years ago
1.1.13
5 years ago
1.1.12
5 years ago
1.1.11
5 years ago
1.1.1
5 years ago
1.1.0
5 years ago
1.0.12
5 years ago
1.0.11
5 years ago
1.0.10
5 years ago
1.0.8
5 years ago
1.0.7
5 years ago
1.0.5
5 years ago
1.0.4
5 years ago
1.0.3
5 years ago
1.0.2
5 years ago
1.0.1
5 years ago
1.0.0
5 years ago