Skip to content

Commit 712a9b0

Browse files
committed
new page on hat click
1 parent 9e46ec9 commit 712a9b0

File tree

3 files changed

+36
-1
lines changed

3 files changed

+36
-1
lines changed

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@
5858
"@types/node": "^18.11.17",
5959
"@types/react": "^18.0.26",
6060
"@types/react-dom": "^18.0.9",
61+
"@uiw/react-md-editor": "^3.20.2",
6162
"antd": "5.1.0",
6263
"antd-mask-input": "2.0.7",
6364
"axios": "^1.2.1",

src/components/LayoutApp.tsx

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ import FileTransfer from './file_transfer/File_transfer';
1919
import PersistedState from 'use-persisted-state';
2020
import MSFBuilder from './linux/MSFBuilder';
2121
import EchoBase64 from './file_transfer/ObfuscatedFiles';
22+
import Notepad from './notepad/Notepad';
2223

2324
const { Paragraph } = Typography;
2425
const { Sider, Content, Footer } = Layout;
@@ -181,6 +182,17 @@ export default function LayoutApp ( props: {
181182
}, [] );
182183

183184
const target = window.location.href;
185+
186+
const handleHatClick = () => {
187+
// navigate( Notepad );
188+
const notepad_route_ctx ={
189+
key: '0',
190+
name: 'Hat Clicked',
191+
componentRoute: Notepad
192+
}
193+
navigate( notepad_route_ctx );
194+
};
195+
184196
return (
185197
<ConfigProvider
186198
theme={{
@@ -201,7 +213,7 @@ export default function LayoutApp ( props: {
201213
left: 0
202214
}}
203215
>
204-
<div className='logo'>
216+
<div className='logo' onClick={handleHatClick}>
205217
<svg xmlns='http://www.w3.org/2000/svg' width='45' height='35' viewBox='0 0 134.624 80.584'>
206218
<g transform='translate(-6.457 -23.8)'>
207219
<path

src/components/notepad/Notepad.tsx

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
import React, { useState } from 'react';
2+
import { Button, Input, Typography, message, Divider, Menu, Dropdown } from 'antd';
3+
import { CopyOutlined, createFromIconfontCN, ClearOutlined, DownOutlined } from '@ant-design/icons';
4+
import Clipboard from 'react-clipboard.js';
5+
import escape_quotes from 'escape-quotes';
6+
7+
const { Title, Paragraph } = Typography;
8+
const IconFont = createFromIconfontCN( {
9+
scriptUrl: [ './iconfont.js' ]
10+
} );
11+
12+
13+
const NOTEPAD = () => {
14+
15+
return (
16+
<div>
17+
NOTEPAD
18+
</div>
19+
);
20+
};
21+
22+
export default NOTEPAD;

0 commit comments

Comments
 (0)