mirror of
https://github.com/wassname/talk.git
synced 2026-07-14 11:18:50 +08:00
Merge branch 'ui-components' of github.com:coralproject/talk into auth-views
* 'ui-components' of github.com:coralproject/talk: Updated code, and snapshots Changes added updated snapshots
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`renders correctly 1`] = `
|
||||
<p
|
||||
className="Typography-root Typography-bodyCopy Typography-colorTextPrimary InputLabel-root custom"
|
||||
<label
|
||||
className="Typography-root Typography-inputLabel Typography-colorTextPrimary InputLabel-root custom"
|
||||
>
|
||||
Hello
|
||||
</p>
|
||||
</label>
|
||||
`;
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
}
|
||||
|
||||
.colorRegular {
|
||||
backgroun-color: var(--palette-common-white);
|
||||
background-color: var(--palette-common-white);
|
||||
color: var(--palette-common-black);
|
||||
border: 1px solid var(--palette-grey-light);
|
||||
}
|
||||
@@ -16,10 +16,18 @@
|
||||
.colorError {
|
||||
background-color: var(--palette-common-white);
|
||||
border-color: var(--palette-error-main);
|
||||
border: 2px solid #FA4643;
|
||||
border: 2px solid var(--palette-error-darkest);
|
||||
}
|
||||
|
||||
.fullWidth {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
::placeholder {
|
||||
font-family: var(--font-family);
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
line-height: calc(16rem / var(--rem-base));
|
||||
font-size: calc(16rem / var(--rem-base));
|
||||
color: var(--palette-grey-lighter);
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ import Flex from '../Flex'
|
||||
## Basic Use
|
||||
<Playground>
|
||||
<Flex itemGutter direction="column">
|
||||
<TextField placeholder="This is a placeholder" />
|
||||
<TextField defaultValue="This is an input field" />
|
||||
<TextField color="error" defaultValue="A TextField with an error" />
|
||||
<TextField color="error" defaultValue="A TextField with an error" fullWidth/>
|
||||
|
||||
@@ -4,5 +4,6 @@ exports[`renders correctly 1`] = `
|
||||
<input
|
||||
className="TextField-root TextField-colorRegular custom"
|
||||
defaultValue="Hello World"
|
||||
placeholder=""
|
||||
/>
|
||||
`;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
.root {
|
||||
composes: validationMessage from "talk-ui/shared/typography.css";
|
||||
composes: alertMessage from "talk-ui/shared/typography.css";
|
||||
position: relative;
|
||||
display: inline-flex;
|
||||
justify-content: flex-start;
|
||||
|
||||
@@ -8,7 +8,6 @@ import ValidationMessage from "./ValidationMessage";
|
||||
it("renders correctly", () => {
|
||||
const props: PropTypesOf<typeof ValidationMessage> = {
|
||||
className: "custom",
|
||||
color: "error",
|
||||
children: "Hello World",
|
||||
};
|
||||
const renderer = TestRenderer.create(<ValidationMessage {...props} />);
|
||||
|
||||
@@ -132,7 +132,7 @@
|
||||
letter-spacing: calc(0.2em / 16);
|
||||
}
|
||||
|
||||
.validationMessage {
|
||||
.alertMessage {
|
||||
color: var(--palette-common-black);
|
||||
font-family: var(--font-family);
|
||||
font-weight: var(--font-weight-medium);
|
||||
@@ -158,3 +158,12 @@
|
||||
letter-spacing: calc(0.2em / 16);
|
||||
color: var(--palette-text-primary);
|
||||
}
|
||||
|
||||
.placeholder {
|
||||
font-family: var(--font-family);
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
line-height: calc(16rem / var(--rem-base));
|
||||
font-size: calc(16rem / var(--rem-base));
|
||||
color: var(--palette-grey-lighter);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user