chore: update demo user

This commit is contained in:
boojack 2022-05-20 06:48:55 +08:00
parent ae87ee6dd0
commit 3fdc5bb2b1
6 changed files with 22 additions and 21 deletions

View File

@ -10,10 +10,10 @@ INSERT INTO
VALUES VALUES
( (
101, 101,
'steven@memos.com', 'demo@usememos.com',
'OWNER', 'OWNER',
'Steven', 'Demo Owner',
'steven_open_id', 'demo_open_id',
-- raw password: secret -- raw password: secret
'$2a$14$ajq8Q7fbtFRQvXpdCq7Jcuy.Rx1h/L4J60Otx.gyNLbAYctGMJ9tK' '$2a$14$ajq8Q7fbtFRQvXpdCq7Jcuy.Rx1h/L4J60Otx.gyNLbAYctGMJ9tK'
); );

View File

@ -38,7 +38,7 @@ const AboutSiteDialog: React.FC<Props> = ({ destroy }: Props) => {
</div> </div>
<div className="dialog-content-container"> <div className="dialog-content-container">
<p> <p>
Memos is an <i>open source</i>, <i>self-hosted</i> knowledge base that works with local SQLite. Memos is an <i>open source</i>, <i>self-hosted</i> knowledge base that works with a SQLite db file.
</p> </p>
<br /> <br />
<p> <p>

View File

@ -2,7 +2,7 @@
.about-site-dialog { .about-site-dialog {
> .dialog-container { > .dialog-container {
@apply w-96; @apply w-112;
> .dialog-content-container { > .dialog-content-container {
@apply leading-relaxed; @apply leading-relaxed;

View File

@ -19,7 +19,7 @@
} }
> .slogan-text { > .slogan-text {
@apply mt-2 text-sm text-gray-600; @apply mt-2 text-sm text-gray-700;
} }
} }
@ -43,15 +43,15 @@
@apply py-2; @apply py-2;
> input { > input {
@apply w-full py-3 px-3 text-base shadow-inner rounded-lg border border-solid border-gray-400; @apply w-full py-3 px-3 text-base shadow-inner rounded-lg border border-solid border-gray-400 hover:opacity-80;
}
}
} }
&:hover { &.requesting {
@apply opacity-80; @apply opacity-80;
} }
} }
}
}
> .action-btns-container { > .action-btns-container {
.flex(row, flex-end, center); .flex(row, flex-end, center);
@ -71,7 +71,7 @@
} }
> .tip-text { > .tip-text {
@apply w-full text-sm mt-4 text-gray-500 text-right; @apply w-full text-sm mt-4 text-gray-500 text-right whitespace-pre-wrap;
} }
} }
} }

View File

@ -26,7 +26,7 @@ const Signin: React.FC<Props> = () => {
api.getSystemStatus().then((status) => { api.getSystemStatus().then((status) => {
setSiteOwner(status.owner); setSiteOwner(status.owner);
if (status.profile.mode === "dev") { if (status.profile.mode === "dev") {
setEmail("steven@memos.com"); setEmail("demo@usememos.com");
setPassword("secret"); setPassword("secret");
} }
pageLoadingState.setFinish(); pageLoadingState.setFinish();
@ -110,28 +110,28 @@ const Signin: React.FC<Props> = () => {
}; };
return ( return (
<div className={`page-wrapper signin ${pageLoadingState.isLoading ? "hidden" : ""}`}> <div className="page-wrapper signin">
<div className="page-container"> <div className="page-container">
<div className="page-header-container"> <div className="page-header-container">
<p className="title-text"> <p className="title-text">
<span className="icon-text"></span> Memos <span className="icon-text"></span> Memos
</p> </p>
<p className="slogan-text"> <p className="slogan-text">
An <i>open source</i>, <i>self-hosted</i> knowledge base that works with local SQLite. An <i>open source</i>, <i>self-hosted</i> knowledge base that works with a SQLite db file.
</p> </p>
</div> </div>
<div className="page-content-container"> <div className={`page-content-container ${actionBtnLoadingState.isLoading ? "requesting" : ""}`}>
<div className="form-item-container input-form-container"> <div className="form-item-container input-form-container">
<span className={"normal-text " + (email === "" ? "" : "not-null")}>Email</span> <span className={`normal-tex ${email ? "not-null" : ""}`}>Email</span>
<input type="email" value={email} onChange={handleEmailInputChanged} /> <input type="email" value={email} onChange={handleEmailInputChanged} />
</div> </div>
<div className="form-item-container input-form-container"> <div className="form-item-container input-form-container">
<span className={"normal-text " + (password === "" ? "" : "not-null")}>Password</span> <span className={`normal-text ${password ? "not-null" : ""}`}>Password</span>
<input type="password" value={password} onChange={handlePasswordInputChanged} /> <input type="password" value={password} onChange={handlePasswordInputChanged} />
</div> </div>
</div> </div>
<div className="action-btns-container"> <div className="action-btns-container">
{siteOwner ? ( {siteOwner || pageLoadingState.isLoading ? (
<button <button
className={`btn signin-btn ${actionBtnLoadingState.isLoading ? "requesting" : ""}`} className={`btn signin-btn ${actionBtnLoadingState.isLoading ? "requesting" : ""}`}
onClick={() => handleSigninBtnsClick()} onClick={() => handleSigninBtnsClick()}
@ -148,8 +148,8 @@ const Signin: React.FC<Props> = () => {
)} )}
</div> </div>
<p className="tip-text"> <p className="tip-text">
{siteOwner {siteOwner || pageLoadingState.isLoading
? "If you don't have an account, please contact the site owner or login as guest." ? "If you don't have an account, please\ncontact the site owner."
: "You are registering as the site owner."} : "You are registering as the site owner."}
</p> </p>
</div> </div>

View File

@ -14,6 +14,7 @@ module.exports = {
}, },
extend: { extend: {
spacing: { spacing: {
112: "28rem",
128: "32rem", 128: "32rem",
168: "42rem", 168: "42rem",
176: "44rem", 176: "44rem",