Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
Doing nothing, what it could be better?

Ciemna_noc Natanagar

💭
Doing nothing, what it could be better?
View GitHub Profile
View gist:7d254768c80e7ce65e12c3b0b20dbb91
import React, { FC, useState } from 'react';
import {
TreeSelect,
Form,
//notification
} from 'antd';
import { CategoriesTreeMock } from '../products/__mock__/treeCategories';
//import getCategoriesStructure from 'src/model/categories/getCategoriesStructure';
const parserDataSelectTree = (array: any[]) => {
View gist:eb4e13e013557ccc046868e4a9520af1
// React libraries
import React, { FC, useState } from 'react';
import CSS from 'csstype';
// third party libraries
import { Icon, Tag as AntdTag } from 'antd';
import {
CheckTagProps,
CrossTagProps,
IconProps,
View Label.tsx
import { Icon, Tag } from 'antd';
import React, { FC, useEffect, useMemo, useState } from 'react';
import styles from './Label.module.scss';
import {
LabelProps,
IconLeftProps,
IconRightProps,
IconTagProps,
CheckLabelProps,
CrossLabelProps,
View gist:80d64158f98af33d40dd6616b18edeb9
import React from 'react';
import { storiesOf } from '@storybook/react';
import { withKnobs, boolean, text, select } from '@storybook/addon-knobs';
import { Center } from '../Center/Center';
import Label from './Label';
const stories = storiesOf('Label', module);
stories.addDecorator((story) => <Center>{story()}</Center>);
stories.addDecorator(withKnobs);
stories.add('Default Color', () => {
View gist:2bf77400041b8885cfc821b163e4f315
import { Icon, Tag } from 'antd';
import React, { FC } from 'react';
import styles from './Label.module.scss';
import { LabelProps, LabelIconProps, LabelCrossProps } from './interfaces';
let className;
const BaseLabel: FC<LabelProps> = (props) => {
const { color, text, opacity, backgroundColor, size } = props;
className = `ant-label-${size}`;
const style = [styles.label, className, styles.position].join(' ');
View mapSaga.js
import React from 'react';
import L from 'leaflet';
import {
put, takeEvery, all, call, delay,
} from 'redux-saga/effects';
import { Position, Apikey } from '../components/utils/index';
import HereTileLayers from '../components/Map/hereTileLayers';
import {
mapStartLoading,
mapIsLoaded,
@Natanagar
Natanagar / App.jsx
Last active Jul 26, 2019
top component
View App.jsx
import React, { useEffect } from 'react';
import { connect } from 'react-redux';
import { Router } from '@reach/router';
import { Footer } from './components/Footer/Footer';
import { Navigation } from './components/Navigation/Navigation';
import { Employer } from './components/Employer/Employer';
import { Employee } from './components/Employee/Employee';
import { mapStartLoading } from './actions/index';
import { mapParams } from './redux-sagas/MapSaga';
import './App.css';
You can’t perform that action at this time.