cleaning up
This commit is contained in:
4
backend/package-lock.json
generated
4
backend/package-lock.json
generated
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"name": "resias-backend",
|
||||
"name": "congruity-backend",
|
||||
"version": "0.1.0",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "resias-backend",
|
||||
"name": "congruity-backend",
|
||||
"version": "0.1.0",
|
||||
"dependencies": {
|
||||
"@anthropic-ai/sdk": "^0.74.0",
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "resias-backend",
|
||||
"name": "congruity-backend",
|
||||
"version": "0.1.0",
|
||||
"description": "Resias AI clustering feature - backend for ProjectPilot",
|
||||
"description": "congruity AI clustering feature - backend for ProjectPilot",
|
||||
"type": "module",
|
||||
"main": "server.js",
|
||||
"scripts": {
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<meta charset="UTF-8" />
|
||||
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>Resias</title>
|
||||
<title>congruity App</title>
|
||||
</head>
|
||||
<body>
|
||||
<div id="root"></div>
|
||||
|
||||
4
frontend/package-lock.json
generated
4
frontend/package-lock.json
generated
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"name": "resias-frontend",
|
||||
"name": "congruity-frontend",
|
||||
"version": "0.1.0",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "resias-frontend",
|
||||
"name": "congruity-frontend",
|
||||
"version": "0.1.0",
|
||||
"dependencies": {
|
||||
"@tanstack/react-query": "^5.90.21",
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "resias-frontend",
|
||||
"name": "congruity-frontend",
|
||||
"private": true,
|
||||
"version": "0.1.0",
|
||||
"type": "module",
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
type ClusterButtonProps = {
|
||||
type ButtonProps = {
|
||||
onClick: () => void;
|
||||
isLoading: boolean;
|
||||
label: string;
|
||||
};
|
||||
|
||||
const ClusterButton = ({ onClick, isLoading }: ClusterButtonProps) => {
|
||||
const Button = ({ onClick, isLoading, label }: ButtonProps) => {
|
||||
return (
|
||||
<button onClick={onClick} disabled={isLoading}>
|
||||
{isLoading ? 'Clustering...' : 'Run Clustering'}
|
||||
{isLoading ? 'Working...' : label}
|
||||
</button>
|
||||
);
|
||||
};
|
||||
|
||||
export default ClusterButton;
|
||||
export default Button;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { useGetStickies, useClusterStickies } from '../api/api';
|
||||
import type { Sticky as StickyType } from '../types/types';
|
||||
import Sticky from './sticky';
|
||||
import ClusterButton from './button';
|
||||
import Button from './button';
|
||||
import './stickies.css';
|
||||
|
||||
const Stickies = () => {
|
||||
@@ -26,7 +26,7 @@ const Stickies = () => {
|
||||
|
||||
return (
|
||||
<div>
|
||||
<ClusterButton onClick={handleCluster} isLoading={isPending} />
|
||||
<Button onClick={handleCluster} isLoading={isPending} label={'Group by Theme'}/>
|
||||
<div className="clusters-container">
|
||||
{clusters.map((group) => (
|
||||
<div key={group.label} className="cluster-group">
|
||||
@@ -46,7 +46,7 @@ const Stickies = () => {
|
||||
|
||||
return (
|
||||
<div>
|
||||
<ClusterButton onClick={handleCluster} isLoading={isPending} />
|
||||
<Button onClick={handleCluster} isLoading={isPending} />
|
||||
<div className="stickies-grid">
|
||||
{stickies?.map((sticky) => (
|
||||
<Sticky key={sticky.id} sticky={sticky} />
|
||||
|
||||
14
frontend/src/components/sticky.css
Normal file
14
frontend/src/components/sticky.css
Normal file
@@ -0,0 +1,14 @@
|
||||
.sticky-note {
|
||||
width: 180px;
|
||||
min-height: 180px;
|
||||
padding: 16px;
|
||||
border-radius: 2px;
|
||||
box-shadow: 2px 4px 8px rgba(0, 0, 0, 0.15);
|
||||
font-family: 'Patrick Hand', cursive, system-ui;
|
||||
font-size: 14px;
|
||||
line-height: 1.4;
|
||||
color: #333;
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
word-break: break-word;
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
import type { Sticky as StickyType } from '../types/types';
|
||||
import './sticky.css';
|
||||
|
||||
const COLOR_MAP: Record<string, string> = {
|
||||
yellow: '#fdfd96',
|
||||
@@ -18,20 +19,9 @@ const Sticky = ({ sticky }: StickyProps) => {
|
||||
|
||||
return (
|
||||
<div
|
||||
className="sticky-note"
|
||||
style={{
|
||||
backgroundColor,
|
||||
width: '180px',
|
||||
minHeight: '180px',
|
||||
padding: '16px',
|
||||
borderRadius: '2px',
|
||||
boxShadow: '2px 4px 8px rgba(0, 0, 0, 0.15)',
|
||||
fontFamily: "'Patrick Hand', cursive, system-ui",
|
||||
fontSize: '14px',
|
||||
lineHeight: '1.4',
|
||||
color: '#333',
|
||||
display: 'flex',
|
||||
alignItems: 'flex-start',
|
||||
wordBreak: 'break-word',
|
||||
transform: `rotate(${Math.random() * 4 - 2}deg)`,
|
||||
}}
|
||||
>
|
||||
|
||||
@@ -3,7 +3,7 @@ import Stickies from '../components/stickies';
|
||||
const Home = () => {
|
||||
return (
|
||||
<div>
|
||||
<h1>Resias - </h1>
|
||||
<h1>kohngrüti</h1>
|
||||
<Stickies />
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user