Giter Club home page Giter Club logo

cathedral's Introduction

Cathedral

cathedral's People

Contributors

mlhaufe avatar dependabot[bot] avatar

Watchers

 avatar

cathedral's Issues

Implement Environment -> Components

"A list of elements of the environment that may affect or be affected by the System and Project. Includes external systems to be interfaced with." HORBA page 40-41.

Components Tab

  • Name: string
  • Description: string
  • Interface description

Add Unit tests

Add unit testing to the project. Use the native Node test runner

Goals Functionality

Implement the Goals Functionality overview.

This includes high level behaviors only

Define Stakeholder map tab

HORABK p. 110

create a separate tab.

Also replace the enumerated stakeholder categories with High/Low pickers

Refactor Routing be a feature of pages

Currently routing requires a standalone table initialized in Application._initRouter():

this.#router = new Router([
    ['/', (await import('./pages/Home.mjs')).Home],
    ['/not-found', (await import('./pages/NotFound.mjs')).NotFound],
    ['/projects', (await import('./pages/projects/Projects.mjs')).Projects],
    ['/environments', (await import('./pages/environments/Environments.mjs')).Environments],
    ['/environments/new-entry', (await import('./pages/environments/NewEnvironment.mjs')).NewEnvironment],
    ['/environments/:slug', (await import('./pages/environments/Environment.mjs')).Environment],
    ['/environments/:slug/glossary', (await import('./pages/environments/Glossary.mjs')).Glossary],
    ['/goals', (await import('./pages/goals/Goals.mjs')).Goals],
    ['/goals/new-entry', (await import('./pages/goals/NewGoals.mjs')).NewGoals],
    ['/goals/:slug', (await import('./pages/goals/Goal.mjs')).Goal],
    ['/goals/:slug/rationale', (await import('./pages/goals/Rationale.mjs')).Rationale],
    ['/goals/:slug/functionality', (await import('./pages/goals/Functionality.mjs')).Functionality],
    ['/goals/:slug/stakeholders', (await import('./pages/goals/Stakeholders.mjs')).Stakeholders],
    ['/goals/:slug/use-cases', (await import('./pages/goals/UseCases.mjs')).UseCases],
    ['/goals/:slug/limitations', (await import('./pages/goals/Limitations.mjs')).Limitations],
]);
this.#router.addEventListener('route', this);

Navigating to a page is accomplished via self.navigation.navigate(pathname)

A problem is that if a route changes, there is no error or warning of usage sites needing to change (Stringly typed)

Additionally, the parameters of the routes currently have to be parsed by subtypes of Page such as in SlugPage:

class SlugPage extends Page {
    // /parent/:slug/foo
    #slug = new URL(location.href, document.location.origin).pathname.split('/')[2];

    constructor(properties: Properties<SlugPage>, children: (string | Element)[]) {
        super(properties, children);

        // ...
    }

    get slug() {
        return this.#slug;
    }
}

Routing should be integrated into the Page class and initiating a route should accomplished via a method call on the page object itself instead of via self.navigate. Additionally, route parameters should be automatically available.

Fix required field render bug

For some reason the .required::after class is not being applied. Is this due to some bug with the shadow DOM or is it a bug with the CSSOM insertRule method?

Refactor Versioning, Mapping, Repositories

Currently all the mappers have the following form:

export interface FooJson extends BaseJson {
    ...props
}

export default class FooToJsonMapper extends BaseToJsonMapper {
    override mapFrom(target: FooJson): Foo {
        const version = target.serializationVersion ?? '{undefined}';

        if (version.startsWith('0.3.'))
            return new Foo(target);
        //... additional versions

        throw new Error(`Unsupported serialization version: ${version}`);
    }

    override mapTo(source: Foo): FooJson {
        return {
            ...super.mapTo(source),
            // ..additionalProps
        };
    }
}

Most repositories are of the form:

export default class FooRepository extends BaseRepository<Foo> {
    constructor() { super('foo', new FooToJsonMapper(pkg.version)); }
}

There is also a LocalStorageRepository specialized for the storage type:

export class LocalStorageRepository<E extends Entity> extends Repository<E> {
    constructor(readonly storageKey: string, mapper: Mapper<E, EntityJson>) {
        super(mapper);
    }

    get storage(): Storage {
        return localStorage;
    }

    get(id: E['id']): Promise<E | undefined> { ... }

    getAll(filter: (entity: E) => boolean = _ => true): Promise<E[]> { ... }

    add(item: E): Promise<void> { ... }

    clear(): Promise<void> { ... }

    update(item: E): Promise<void> { ... }

    delete(id: E['id']): Promise<void> { ... }
}

Note the storage member which was defined to support unit testing:

const fakeStorage: Storage = new DomStorage(null, { strict: true });

class TestLocalStorageRepository<F extends Foo> extends LocalStorageRepository<F> {
    override get storage() {
        return fakeStorage;
    }
}

This smells and has significant duplication. This needs to be done better

Implement Environment -> Assumptions

An Assumption is a property of an environment that may be assumed. They are not imposed by the environment. Example: Client Screen resolutions will be larger than 1024x768

Change component rendering approach

Rendering is still a bit awkward. The Template Method pattern approach causes problems with private field access which leads to verbose workarounds in certain cases

Implement System -> Functionality

Describes the behaviors (functional and non-functional) of Components. What the system does

UML models exist:
image

Is this a 1 to many relationship between components and the diagrams?

Remove license headers

Remove license headers from files.

With a LICENSE file in place this is sufficient. the header becomes redundant and introduces a maintenance burden for the year.

DataTable vs Domain uniqueness

Currently the DataTable enforces uniqueness constraint on entries.

The Domain should probably enforce this instead. Research a way to accomplish this.

Implement Environment -> Constraints

"Obligations and limits imposed on the project and system by the environment" HORABA page 40-41

"[A]n environment property that may affect components, goals, behaviors, tasks or products" The Anatomy of Software Requirements

  • statement
  • category: Business Rule | Physical Law | Engineering Decision

Implement System -> Scenarios

Interactions between the environment, Actors, and the system

Use Cases
User Stories

Need to reference Goals -> Use Cases

Implement storage versioning

Implement storage versioning to support schema evolution.

This is dependent on determining the ultimate storage strategy.

If it remains JSON one approach is to utilize the package version and have the data layer do the mapping based on the versions

Refresh when updated

As an SPA, when an update is deployed clients have a good chance of not being updated due to long running sessions.

Migrate away from Nuxt/Vue

The framework has become more trouble than it's worth.

  • Implicit Globals
  • Build sizes too large
  • Can't practically avoid server components
  • nuxi generate creates a non-functional build
  • plugins poorly maintained
  • requires custom plugins in the IDE to develop (and it won't type check properly)
  • The router is buggy and requires sibling dummy pages to get subpaths to work properly
  • etc.

Deprecate Navigation API polyfill

The project currently utilizes the Navigation API to intercept navigation events and handle them

As of 2023-11-01, the Navigation API is still experimental and supported
by only Chromium-based browsers (~73% coverage as of January 2024)

https://developer.mozilla.org/en-US/docs/Web/API/Navigation_API
https://developer.chrome.com/docs/web-platform/navigation-api/
https://caniuse.com/mdn-api_navigation

Types are polyfilled via dom-navigation package

Once the feature is fully adopted by major browsers, remove the polyfill

Add hover effect to cards

For consistency, the MiniCards and PEGSCards should have a hover effect like the other navigable elements

Fix Stakeholder map positioning

image

Currently the stakeholders are all plotted at the origin of each quadrant.

The Stakeholder model needs to updated to include availability and influence fields.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.