mirror of
https://github.com/microsoft/frontend-bootcamp.git
synced 2026-01-26 14:56:42 +08:00
adding back docs
This commit is contained in:
@@ -2,5 +2,5 @@
|
||||
<html>
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
<script type="text/javascript" src="../../step2-03/demo/step2-03/demo.js"></script></body>
|
||||
<script src="../../step2-03/demo/step2-03/demo.js"></script></body>
|
||||
</html>
|
||||
|
||||
@@ -29,9 +29,22 @@ export class TodoHeader extends React.Component<TodoHeaderProps, TodoHeaderState
|
||||
|
||||
<Stack horizontal gap={10}>
|
||||
<Stack.Item grow>
|
||||
<TextField placeholder="What needs to be done?" value={this.state.labelInput} onChange={this.onChange} />
|
||||
<TextField
|
||||
placeholder="What needs to be done?"
|
||||
value={this.state.labelInput}
|
||||
onChange={this.onChange}
|
||||
styles={props => ({
|
||||
...(props.focused && {
|
||||
field: {
|
||||
backgroundColor: 'black'
|
||||
}
|
||||
})
|
||||
})}
|
||||
/>
|
||||
</Stack.Item>
|
||||
<PrimaryButton onClick={this.onAdd}>Add</PrimaryButton>
|
||||
<PrimaryButton onClick={this.onAdd} styles={{ root: { backgroundColor: 'maroon' }, rootHovered: { background: 'green' } }}>
|
||||
Add
|
||||
</PrimaryButton>
|
||||
</Stack>
|
||||
|
||||
<Pivot onLinkClick={this.onFilter}>
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -2,5 +2,5 @@
|
||||
<html>
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
<script type="text/javascript" src="../../step2-03/exercise/step2-03/exercise.js"></script></body>
|
||||
<script src="../../step2-03/exercise/step2-03/exercise.js"></script></body>
|
||||
</html>
|
||||
|
||||
@@ -10,6 +10,7 @@ import { TeamsCustomizations } from '@uifabric/theme-samples';
|
||||
|
||||
let index = 0;
|
||||
|
||||
// TODO: Change this to add other CSS styles like backgroundColor, fontSize, etc
|
||||
const className = mergeStyles({
|
||||
padding: 25,
|
||||
...getTheme().effects.elevation4
|
||||
|
||||
@@ -12,6 +12,9 @@ interface TodoFooterProps {
|
||||
export const TodoFooter = (props: TodoFooterProps) => {
|
||||
const itemCount = Object.keys(props.todos).filter(id => !props.todos[id].completed).length;
|
||||
|
||||
// TODO: play around with the DefaultButton component below with a "styles" prop
|
||||
// - try it with an object: styles={{ ... }}
|
||||
// - try it with a function: styles={props => ({ ... })}
|
||||
return (
|
||||
<Stack horizontal horizontalAlign="space-between">
|
||||
<Text>
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user