Skip to content
This repository has been archived by the owner on Apr 4, 2022. It is now read-only.

Commit

Permalink
redwood 0.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
chris-hailstorm committed Apr 1, 2020
1 parent 4d8293a commit d6e9896
Show file tree
Hide file tree
Showing 5 changed files with 1,429 additions and 1,292 deletions.
2 changes: 1 addition & 1 deletion api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "0.0.0",
"private": true,
"dependencies": {
"@redwoodjs/api": "^0.3.0",
"@redwoodjs/api": "^0.4.0",
"semantic-ui-react": "^0.88.2"
}
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
]
},
"devDependencies": {
"@redwoodjs/core": "^0.3.0"
"@redwoodjs/core": "^0.4.0"
},
"eslintConfig": {
"extends": "@redwoodjs/eslint-config"
Expand Down
4 changes: 2 additions & 2 deletions web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"version": "0.0.0",
"dependencies": {
"@gouch/to-title-case": "^2.2.1",
"@redwoodjs/router": "^0.3.0",
"@redwoodjs/web": "^0.3.0",
"@redwoodjs/router": "^0.4.0",
"@redwoodjs/web": "^0.4.0",
"filestack-react": "^3.1.0",
"html-truncate": "^1.2.2",
"markdown-it": "^10.0.0",
Expand Down
8 changes: 8 additions & 0 deletions web/src/components/Admin/PostForm/PostForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import {

import ReactFilestack from 'filestack-react'

import 'semantic-ui-css/semantic.css'
import { Dropdown } from 'semantic-ui-react'

import TagsDataCell from 'src/components/Blog/TagsDataCell'
Expand Down Expand Up @@ -72,6 +73,7 @@ const PostForm = (props) => {

const replaceImage = (event) => {
event.preventDefault()

setSplashImage(null)
}

Expand All @@ -96,6 +98,7 @@ const PostForm = (props) => {
validation={{ required: true }}
/>
<FieldError name="title" className={CSS.error} />

<Label
name="slug"
className={CSS.label}
Expand Down Expand Up @@ -165,6 +168,7 @@ const PostForm = (props) => {
validation={{ required: true }}
/>
<FieldError name="author" className={CSS.error} />

<Label
name="body"
className={CSS.label}
Expand All @@ -178,7 +182,9 @@ const PostForm = (props) => {
validation={{ required: true }}
/>
<FieldError name="body" className={CSS.error} />

<label className={CSS.label}>Splash Image</label>

<ReactFilestack
apikey={process.env.FILESTACK_API_KEY}
onSuccess={onFileUpload}
Expand All @@ -191,10 +197,12 @@ const PostForm = (props) => {
fromSources: ['local_file_system', 'url'],
}}
/>

<div
id="embedded"
className={`h-80 ${splashImage ? 'hidden' : ''}`}
></div>

{splashImage && (
<div className="mt-2">
<img src={splashImage} alt="Splash image" className="max-h-80" />
Expand Down
Loading

0 comments on commit d6e9896

Please sign in to comment.