Giter VIP home page Giter VIP logo

hbo-i / ictresearchmethods.nl Goto Github PK

View Code? Open in Web Editor NEW
9.0 2.0 12.0 13.9 MB

The ICT Research Methods is a set with research methods for design-oriented research within ICT

Home Page: https://ictresearchmethods.nl

License: Creative Commons Zero v1.0 Universal

JavaScript 0.44% HTML 0.92% SCSS 1.42% Svelte 92.70% TypeScript 4.50% Shell 0.01%
svelte sveltekit typescript performance svelte-testing-library

ictresearchmethods.nl's People

Contributors

bartvanderwal avatar elmar-wiese avatar imreboersma avatar jochemvogel avatar lucky-loek avatar nowarries avatar ralphniels avatar vkreuzen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

ictresearchmethods.nl's Issues

Active category to center on mobile

Is your feature request related to a problem? Please describe.
Small UX flaw

Describe the solution you'd like
When a category is selected on mobile it will be centered, so the previous and next category will also be visible. Right now this does not happen and it doesn't look like there is another category. You need to (horizontal) scroll in order to go to the next one.

Fix dropdown search

Little bit broke right now. Tbh it never really worked good, so fix that.

Add error.html and update __tests__ to tests

Describe the problem

Just some changes based on the new version of sveltekit

error.html (optional) is the page that is rendered when everything else fails. It can contain the following placeholders:
%sveltekit.status% โ€” the HTTP status
%sveltekit.error.message% โ€” the error message

https://kit.svelte.dev/docs/routing#error

tests/ folder is outside the src/ folder now

Describe the proposed solution

Alternatives considered

No response

Importance

would make my life easier

Additional Information

No response

Update workflow

In the workflows (Github Actions) we use environment variables/secrets. Those are not accessible in forked repos. So when people try to make a change, the CI will fail, because they don't have access to the secrets.

Update pull_request to pull_request_target will probably do the trick. This isn't a very safe way according this article, but for this repo that's not a big deal.

Github fixed it tho, but (logically) only for private repos.

Only necessary for the Development CI, that's the only one that's triggered when a fork is being merged.

https://github.com/jochemvogel/ictmethods.nl/pull/47

Sources:

Update to new SvelteKit best practices

SvelteKit is updated lately and there are a few new best practices available that are not implemented in the app right now:


1).

/library/available-product-analysis is valid, but /test-url/i-dont-know is not. Figure out if you can fix this with matching. Error handling will be better if you do it like that.

You can say 'method is not available' instead of 'page is not available'

Images are not prefetched

Describe the bug

Images need to load on method page while they have to be prefetched

Reproduction

Compare: https://deploy-preview-58--dev-ictmethods.netlify.app/library with https://deploy-preview-57--dev-ictmethods.netlify.app/library.

On both versions go to a method page. On the '57 one' the images are already loaded, while on the '58 one' they're loaded when on the page.

Expected Behavior

Load instantly like https://deploy-preview-57--dev-ictmethods.netlify.app/library

System Information

All

Severity

annoyance

Additional Information

Changed because of this: https://github.com/jochemvogel/ictmethods.nl/pull/58.

An assumption is that I added thumbnails. Those are not the same resources as the images on the method page. Strange anyways, because they've to be prefetched.

Splash screen

Is your feature request related to a problem? Please describe.
No, just a splash screen on mobile gives a better UX

Add more tests

Currently there are only some setup/basic tests. This needs to be increased. Think about (for now) at least five main functionalities you'd like to test.

Double check mobile

Logo in topbar and image in machine learning are not optimised. Won't take that long, but optimise it for mobile devices.

Add a fallback image to the method cards

src/lib/components/method/MethodCard.svelte

When there is no image provided for a specific method, a 404 will been thrown. Solution could be something like this (but then it has to work):

<script>
  let fallbackLoaded = false;

  function handleImageError(event) {
    if (!fallbackLoaded) {
      fallbackLoaded = true;
      event.target.src = '/img/fallback.jpg';
    }
  }
</script>

<picture class="card-heading__img">
  <source
    type="image/webp"
    srcset={`/img/methods/${method.category}/thumbnail/${method.slug}.webp`}
  />
  <source
    type="image/jpeg"
    srcset={`/img/methods/${method.category}/thumbnail/${method.slug}.jpg`}
  />
  <img
    src={`/img/methods/${method.category}/thumbnail/${method.slug}.jpg`}
    loading="lazy"
    decoding="async"
    class="img"
    alt=""
    height="80"
    width="80"
    on:error={handleImageError}
  />
</picture>

Save methods to favorites

Describe the solution you'd like
Probably with local storage to make sure that users can save them. See if it is also possible if users have turned off their JS. What if their offline? IndexedDB? Disable saving? Disable link in nav? Think about it.

Remove all unused css

Lot of classes in css are not being used. Build the repo and remove everything that is flagged

Fix layout shift on load

There seems to be a layout switch when you enter the page. Put 'low-end mobile' throttling on in browser to check differences

Fixed width and height to method cards/articles

  1. Width of card => Is less wide after 'mounted' (CSS gap property on article?)
  2. Height of card
  3. Font-size/scale?

Keep dark/light theme on search page

Describe the bug

On the search page the theme resets to light.

Reproduction

Go to the search page with dark mode enabled

Expected Behavior

Dark mode stays enabled (it's the same app)

System Information

Everything

Severity

annoyance

Additional Information

Something is going on with SSR. Search is the only 'not prerendered' page.

Make sidebar sticky

Is your feature request related to a problem? Please describe.
It currently looks kinda weird in combination with the footer.

Describe the solution you'd like
Sticky sidebar so the navigation will be visible the whole time and the footer doesn't look weird

'Not found' method will throw 500

Describe the bug

When you go to a method that does not exist, SvelteKit tries to fetch that one from API and that results in a 500

Unexpected end of JSON input

SyntaxError: Unexpected end of JSON input

Reproduction

https://ictmethods.nl/workshop/dasfadsf will throw a 'Invocation failed'

Expected Behavior

Serve to 404 page

System Information

All devices

Severity

annoyance

Additional Information

No response

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.