Skip to content
This repository has been archived by the owner on Jan 19, 2025. It is now read-only.

feat: description annotation #536

Merged
merged 28 commits into from
Jun 13, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
9ec9ed3
feat: process description annotations in backend
lars-reimann Jun 3, 2022
2d18515
feat: update validation in backend
lars-reimann Jun 3, 2022
e129011
feat(backend): actually trigger processing
lars-reimann Jun 3, 2022
2cfafbc
style: apply automatic fixes of linters
lars-reimann Jun 3, 2022
4fc0cc9
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 4, 2022
497c8d7
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 5, 2022
6c269b9
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 5, 2022
69a658b
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 11, 2022
fe6f8a4
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 12, 2022
dee4cb8
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 12, 2022
b8c7ed9
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 13, 2022
3599178
feat: Adding description annotation (WIP)
Masara Jun 13, 2022
4d81cc2
Merge remote-tracking branch 'origin/517-description-annotation' into…
Masara Jun 13, 2022
3ab3f55
revert: changes to Kotlin files
lars-reimann Jun 13, 2022
0a21539
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 13, 2022
c1726ca
feat: Added description annotation, a filter for it and adjusted the …
Masara Jun 13, 2022
55b6d3c
style: apply automatic fixes of linters
Masara Jun 13, 2022
6178c93
Merge branch 'main' into 517-description-annotation
lars-reimann Jun 13, 2022
9a3c77d
feat: don't show new description in annotation view (long)
lars-reimann Jun 13, 2022
a98d466
fix: build error
lars-reimann Jun 13, 2022
0357b36
feat: consistent label for new description text area
lars-reimann Jun 13, 2022
8303247
refactor: sort stuff
lars-reimann Jun 13, 2022
9fc7701
fix: description annotations not sent to server
lars-reimann Jun 13, 2022
ad0d06e
fix: remove log
lars-reimann Jun 13, 2022
b8d29b9
refactor: sort stuff
lars-reimann Jun 13, 2022
04a1037
refactor: sort stuff
lars-reimann Jun 13, 2022
5080c82
style: apply automatic fixes of linters
lars-reimann Jun 13, 2022
ac16cfe
fix: build error
lars-reimann Jun 13, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: build error
  • Loading branch information
lars-reimann committed Jun 13, 2022
commit a98d466c3903a9852b361cda78bfc40129de98a8
11 changes: 8 additions & 3 deletions api-editor/gui/src/app/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ import {
selectFilteredPythonPackage,
selectPythonPackage,
} from '../features/packageData/apiSlice';
import { PythonClass } from '../features/packageData/model/PythonClass';
import { PythonParameter } from '../features/packageData/model/PythonParameter';

export const App: React.FC = function () {
useIndexedDB();
Expand Down Expand Up @@ -104,9 +106,12 @@ export const App: React.FC = function () {
{currentUserAction.type === 'constant' && (
<ConstantForm target={userActionTarget || pythonPackage} />
)}
{currentUserAction.type === 'description' && (
<DescriptionForm target={userActionTarget || pythonPackage} />
)}
{currentUserAction.type === 'description' &&
(userActionTarget instanceof PythonClass ||
userActionTarget instanceof PythonFunction ||
userActionTarget instanceof PythonParameter) && (
<DescriptionForm target={userActionTarget} />
)}
{currentUserAction.type === 'enum' && <EnumForm target={userActionTarget || pythonPackage} />}
{currentUserAction.type === 'group' && (
<GroupForm
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,12 @@ import { PythonDeclaration } from '../../packageData/model/PythonDeclaration';
import { selectDescription, upsertDescription } from '../annotationSlice';
import { AnnotationForm } from './AnnotationForm';
import { hideAnnotationForm } from '../../ui/uiSlice';
import {PythonClass} from "../../packageData/model/PythonClass";
import {PythonFunction} from "../../packageData/model/PythonFunction";
import {PythonParameter} from "../../packageData/model/PythonParameter";

interface DescriptionFormProps {
readonly target: PythonDeclaration;
readonly target: PythonClass | PythonFunction | PythonParameter;
}

interface DescriptionFormState {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import { Optional } from '../../../common/util/types';

export abstract class PythonDeclaration {
abstract readonly name: string;
abstract readonly description: string;

abstract parent(): Optional<PythonDeclaration>;

Expand Down