on master help sign in
move ColorInput
a580001Liam Fitzgerald
src/indigo-react/components/ColorInput.js → src/form/ColorInput.jsrenamed+1−1
@@ -1,7 +1,7 @@
1import React from 'react';
1import React from 'react';
2import { useField } from 'react-final-form';
2import { useField } from 'react-final-form';
3import cn from 'classnames';
3import cn from 'classnames';
4−import Flex from './Flex';
4+import { Flex } from 'indigo-react';
5
5
6const ColorInput = ({ name, colors, disabled = false, label, className }) => {
6const ColorInput = ({ name, colors, disabled = false, label, className }) => {
7 const { input } = useField(name, { subscription: { value: true } });
7 const { input } = useField(name, { subscription: { value: true } });
src/indigo-react/index.js−1
@@ -9,6 +9,5 @@ export { default as AccessoryIcon } from './components/AccessoryIcon';
9export { default as Button } from './components/Button';
9export { default as Button } from './components/Button';
10export { default as IconButton } from './components/IconButton';
10export { default as IconButton } from './components/IconButton';
11export { default as LinkButton } from './components/LinkButton';
11export { default as LinkButton } from './components/LinkButton';
12−export { default as ColorInput } from './components/ColorInput';
13
12
14export * from './components/Typography';
13export * from './components/Typography';
src/views/SigilGenerator.js+2−1
@@ -1,5 +1,5 @@
1import React, { useRef, useCallback } from 'react';
1import React, { useRef, useCallback } from 'react';
2−import { Grid, Flex, ColorInput } from 'indigo-react';
2+import { Grid, Flex } from 'indigo-react';
3import * as ob from 'urbit-ob';
3import * as ob from 'urbit-ob';
4import { FORM_ERROR } from 'final-form';
4import { FORM_ERROR } from 'final-form';
5import { colors } from 'indigo-tokens';
5import { colors } from 'indigo-tokens';
@@ -18,6 +18,7 @@ import BridgeForm from 'form/BridgeForm';
18import FormError from 'form/FormError';
18import FormError from 'form/FormError';
19import SubmitButton from 'form/SubmitButton';
19import SubmitButton from 'form/SubmitButton';
20import { NumberInput } from 'form/Inputs';
20import { NumberInput } from 'form/Inputs';
21+import ColorInput from 'form/ColorInput';
21
22
22const BG_COLORS = [
23const BG_COLORS = [
23 colors.black,
24 colors.black,