For generate a link with SSO mode use this shortcode:
[multisto-sso class="%CLASS%"]%CONTENT%[/multisto-sso]
%CLASS%
| const Box = styled.div` | |
| display: block; | |
| ${p => p.width && css`width: ${p.width};`} | |
| ${flexChildMixin} | |
| ${buildResponsiveWidthMixin} | |
| `; | |
| // example | |
| <Box xs={4} md={6} /> |
| export const replacePattern = (template, data) => { | |
| const _pattern = /\{\{(.*?)\}\}/g; // {{property}} | |
| return template.replace(_pattern, (match, token) => data[token] || ''); | |
| }; |
| const useTimer = (calc, delay = 1000, deps = []) => { | |
| const [time, setTime] = useState(''); | |
| useEffect(() => { | |
| const timer = Meteor.setInterval(() => { | |
| setTime(calc); | |
| }, delay); | |
| return () => { | |
| Meteor.clearInterval(timer); |
| import React from 'react'; | |
| import PropTypes from 'prop-types'; | |
| import styled from 'styled-components'; | |
| import { withAccount } from 'core/api/accounts/accountContext'; | |
| const COLORS_MAP = [ | |
| '#6C61AC', | |
| '#C25F77', | |
| '#9461AC', |
| import React, { PureComponent } from 'react'; | |
| import PropTypes from 'prop-types'; | |
| import withStore from './StoreContext'; | |
| @withStore | |
| class MyComponent extends PureComponent { | |
| static propTypes = { | |
| setStore: PropTypes.func.isRequired, | |
| // значение из стора, для простоты пусть это будет число, но может быть и объектом |
| import React, { PureComponent } from 'react'; | |
| import styled, { css } from 'styled-components'; | |
| class Header extends PureComponent { | |
| state = { | |
| isFixed: false, | |
| }; | |
| componentDidMount() { | |
| const el = document.getElementById('scroll-cont'); |
| class Collection { | |
| constructor(doc) { | |
| Object.assign(this, doc); | |
| } | |
| // общие методы для документов всех коллекций | |
| } | |
| class Link extends Collection { | |
| // методы для документов коллекций Link | |
| } |
| How to Completely Remove Android Studio | |
| Execute these commands from the terminal | |
| rm -Rf /Applications/Android\ Studio.app | |
| rm -Rf ~/Library/Preferences/AndroidStudio* | |
| rm ~/Library/Preferences/com.google.android.studio.plist | |
| rm -Rf ~/Library/Application\ Support/AndroidStudio* | |
| rm -Rf ~/Library/Logs/AndroidStudio* |
| Statement = new Mongo.Collection('statement'); | |
| Statement.helpers({ | |
| autoInfo() { | |
| if (this.autoText) { | |
| return this.autoText; | |
| } | |
| var a = Meteor.subscribe('userAuto', { | |
| _id: this.auto, | |
| owner: this.owner |