Git Product home page Git Product logo

Comments (24)

BryanWilhite avatar BryanWilhite commented on June 26, 2024
ng generate library @songhay/index --prefix=rx
npm i --save ngx-pagination normalize.css @angular/flex-layout

i see from my note that i may need material-design-icons (with mdi) but i think my later work with SVG will eliminate the need; also, i made no note about why i would need hammerjs

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

the BlogEntry model in angular.io-index-app should be ignored as it is already here: https://github.com/BryanWilhite/Songhay.Blog/blob/master/Songhay.Blog/ClientApp/src/app/models/songhay-blog-entry.ts

the Domain conversion pattern of the Songhay observable data store would be used, finally making a coherent resolution for this issue: https://github.com/BryanWilhite/angular.io-index-app/issues/1

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

i declared IndexEntriesStore feature complete (028271c) because filterEntries re-factored to use DisplayItemModel is the only feature that should be shared in the Index library

my declaration is based on the assumption that IndexEntriesStore will be provided like this:

{ provide: IndexEntriesStore, useClass: YourClassExtendingIndexEntriesStore }

next move:

ng generate component components/index-container --flat=true --module=index/src/lib/index --project=@songhay/index --skip-tests=false --style=scss --dry-run=true
ng generate component components/index-groups --flat=false --module=index/src/lib/index --project=@songhay/index --skip-tests=false --style=scss --dry-run=true
ng generate component components/index-list --flat=false --module=index/src/lib/index --project=@songhay/index --skip-tests=false --style=scss --dry-run=true
ng generate component components/error --flat=false --module=index/src/lib/index --project=@songhay/index --skip-tests=false --style=scss --dry-run=true

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

this last push, 5a6febd, is my first attempt to inject options into a module, following the β€œNgModule forRoot() Convention”

ah, i incorrectly assumed that forRoot referred to root routes:

By importing the providers at the root, it helps ensure that all lazy-loaded NgModules get the same instance of the provider and is why forRoot() is named as such.

the article referenced above does not make mention of forChild [GitHub] which is in the same source file as forRoot

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

weird stuff i did:

-updated these packages to @latest: @angular-devkit/build-ng-packagr, @angular/cli, @angular-devkit/build-angular, @angular/compiler-cli

  • added an index/src/assets folder

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

index groups issue:
image

what the red squigglies are really saying is that the legacy code returned an array of object with an itemCategoryObject embedded as ad-hoc JSON with a groupByPropertyName; in the β€˜new’ code, this should map to Sortable.itemCategory somehow which implies that a category is being used for grouping

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

i added IndexOptions.indexRouterLink to allow lib consumers to link into the content of their domain

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

two commits to songhay-core, BryanWilhite/songhay-core@4e89e11 and BryanWilhite/songhay-core@9880894, represent my latest understanding about DisplayItemModel

DisplayItemModel.sortOrdinal and DisplayItemModel.id should be string | number; this composite typing is not possible in C# which is why it has taken me so long to figure this out πŸ‘Ž

commit b70b3b1 is revealing the fact that the only β€˜customer’ for IndexEntriesStore is my blog site with its BlogEntry domain type

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

last bit on this plate: IndexLibModule

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

sort ordinal has been addressed but not topics; the index should derive topics data for topics grouping with formal models

any such client-side metadata might do well in a dictionary on the server side, a general-purpose thing like DisplayItemModel.ClientBag

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

trying to inject MockDomainStore with this:

export function provideEntriesStore<TStore extends IndexEntriesStore>(dataStoreType: TStore): {}[] {
    return [{ provide: IndexEntriesStore, useClass: dataStoreType }];
}

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

what should be formally addressed (should have its own issue but probably will not πŸ‘Ž ) is the translation of Index grouping into MenuDisplayItemModel [GitHub]

what also should be recognized in a design document i do not know how write (right now) are Index app topics; the legacy basically crammed a packet of serialized JSON into a semi-arbitrary itemCategoryObject [StackBlitz]

this cramming was basically a sad attempt to associate a loosely-defined object with a formal model; what might be improvement is to bake something with these ingredients:

  • a property of Map<string, object> hanging off some interface (Sortable or Groupable?)
  • use MenuDisplayItemModel to extend from this interface

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

not looking πŸ‘€ great:

image

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

next is getting something like this into songhay-core:

const pad = (num: string | number, size: number) => {
    let s = String(num);
    while (s.length < size) {
        s = `0${s}`;
    }
    return s;
};

update: try http://numeraljs.com/ instead

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

i see πŸ‘€ that the array-map call to generate topic key-value pairs which get turned to into a Map can be generalized into an overload for MapObjectUtility.getMap

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

actually an improvement from the last πŸ‘€ time:
image

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

this issue will help here: BryanWilhite/songhay-core#9

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

IndexGroupingOption needs to be added to IndexOptions; this will allow grouping options to match groups attached to Selectable.map

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

this might be the sutra sought for:

image

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

wow πŸ‘€:
image

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

for testing:
image

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

ran into this issue: https://flaviocopes.com/how-to-check-undefined-property-javascript/

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

getting a bit sleepy
image

group switching is not working
image

from songhay-ng-workspace.

BryanWilhite avatar BryanWilhite commented on June 26, 2024

better:
image

okay people πŸ™„ let’s wrap this up:
image

  • use the old, ancient, old πŸ₯€πŸ§™πŸΎβ€β™‚️ HTML-comment trick to get [No Grouping] to sort ascending to the bottom
  • add a TODO to add support for a custom fallback group other than [No Grouping]
  • break out new issues for CSS styling options and routing investigation

it must be mentioned that the legacy Edge browser is painfully slow while trying to group by date (the largest set of groups):

image

it is much, much faster on Chrome; this HTML parsing hit could come from calling sanitizer.bypassSecurityTrustHtml O(2n) times (from the HTML template instead of code)β€”which leads me to ask the question, β€˜Can I use a framework agnostic version of SafeHtml in songhay-core?’

well, it turns out that SafeHtml is nothing:

image

the Angular team regards these types as marker interfaces

BTW: this investigation led to another question, β€˜How do the other frameworks address the β€œsafe” HTML concept?’ =>

from songhay-ng-workspace.

Related Issues (20)

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.