Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH+NF: add javascript customization options via config #283

Merged
merged 2 commits into from
Apr 13, 2023

Conversation

jsheunis
Copy link
Member

This PR:

Both are done by allowing more configuration options via the config file, basically resulting in show/hide logic for certain UI components.

In order to apply these changes to an existing catalog, the affected html and javascript files will have to be checked out into the existing catalog repo, and the catalog's config file will need to be updated with the "social_links" and "dataset_options" fields.

Towards parts of sfb1451/metadata-catalog#5

@codecov-commenter
Copy link

codecov-commenter commented Apr 13, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (377fffe) 82.67% compared to head (b009163) 82.67%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #283   +/-   ##
=======================================
  Coverage   82.67%   82.67%           
=======================================
  Files          32       32           
  Lines        2164     2164           
=======================================
  Hits         1789     1789           
  Misses        375      375           
Flag Coverage Δ
unittests 72.06% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Member

@mih mih left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not have efficient means to generate a test catalog to see the effects of the proposed changes, and there are no screenshots provided -- so my comments are superficial and from skimming the diff. LGTM.

@jsheunis
Copy link
Member Author

Ooh sorry (it's about time to implement #273 then)

Here are some examples:

1

config: {
    ...
    "social_links": {
        "about": null,
        "documentation": null,
        "github": null,
        "twitter": null
    },
    "dataset_options": {
        "include_metadata_export": false
    },
    ...
}

Screenshot 2023-04-13 at 09 00 42

2

config: {
    ...
    "social_links": {
        "about": null,
        "documentation": "https://docs.datalad.org/projects/catalog/en/latest/",
        "github": "https://github.com/datalad/datalad-catalog",
        "twitter": "https://twitter.com/datalad"
    },
    "dataset_options": {
        "include_metadata_export": true
    },
    ...
}

Screenshot 2023-04-13 at 08 59 36

@jsheunis
Copy link
Member Author

Ok, fire in the hole.

@jsheunis jsheunis merged commit 812a2fb into main Apr 13, 2023
jsheunis added a commit to jsheunis/sfb1451-projects-catalog that referenced this pull request Apr 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants