Git Product home page Git Product logo

morea's People

Contributors

philipmjohnson avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

morea's Issues

GitHub Action fails for pre-January 2024 Morea sites

If you have an existing pre-2024 Morea site and try to build it after January, 2024, you will find that your GitHub action fails due to changes at GitHub.

To fix this, you must do the following:

  1. Update your .github/workflows/main.yml file to be the same as the current one:
  1. In your browser:
  • Go to your morea repo in GitHub,
  • Click "Settings"
  • Select "Pages" from the left side menu
  • Under "Build and Deployment", select "Github Actions"

Now you should be able to rebuild your site without problems.

Support iCalendar integration

Many students have requested the ability to "subscribe" to Schedule page events so that they would show up on their own Google Calendar without having to look at the Schedule page.

It would appear that this could be possible by updating the Morea plugin to write out an iCalendar calendar file containing the latest entries each time the system is built. The following Ruby library appears to support that:

https://github.com/icalendar/icalendar

Then we could just provide the URL to that file to interested students.

It appears that there are issues with the frequency with which Google syncs your calendar with these feeds. It could hours or days before it happens. This might make this feature less useful (or even unrecommended).

Fix default behavior of morea_sort_order

The sort order field should default to 1 if missing or empty. Currently, an empty field generates an error:

Generating...
D:/GitHub/ics111f21/_plugins/MoreaGenerator.rb:163:in `sort_by': comparison of Integer with nil failed (ArgumentError)
        from D:/GitHub/ics111f21/_plugins/MoreaGenerator.rb:163:in `sort_pages'
        from D:/GitHub/ics111f21/_plugins/MoreaGenerator.rb:142:in `generate'
        from D:/Applications/Ruby30-x64/lib/ruby/gems/3.0.0/gems/jekyll-4.2.0/lib/jekyll/site.rb:193:in `block in generate'
        from D:/Applications/Ruby30-x64/lib/ruby/gems/3.0.0/gems/jekyll-4.2.0/lib/jekyll/site.rb:191:in `each'
        from D:/Applications/Ruby30-x64/lib/ruby/gems/3.0.0/gems/jekyll-4.2.0/lib/jekyll/site.rb:191:in `generate'

Create morea-portal template repository

The courses.ics site (uhmanoa.github.io) is based on Morea 2, and thus obsolete versions of Jekyll, Bootstrap, etc.

It should be relatively easy to refresh that site, and as part of the process, create a template repository in the Morea Framework for any organization who wants to make a "portal" site that provides access to a collection of Morea 3 sites.

Start by making a template of morea called morea-portal. That gives you an up to date Jekyll, Bootstrap, and Bootswatch. Then redo the layouts and markdown files so that you are building something similar to courses.ics.hawaii.edu.

I don't know if the module browser, or syllabus directory, and so forth is useful. The initial version of the site could simply be the review site page.

Schedule does not start on month for current day

In migrating to V3 I noticed that the Schedule calendar does not automatically start on the month for the current day. If you press the today button it will set the calendar to the month for the current day.

I have not looked into weather this is a feature, bug, or incompatibility between MOREA V2 and V3 schedules (my guess is the latter). I'm not sure if I copied the V2 schedule templates when I migrated to V3.

bootstrap label classes missing in bootstrap V5

In migrating to V3 I found assessment-chartjs-wod.html uses bootstrap label classes

label-success
label-info
label-warning
label-danger

which seem to have been removed in bootstrap V5 (but I found them in bootstrap V3). I didn't find any suggested replacements in the bootstrap V5 docs so I just added them in to the style for assessment-chartjs-wod.html.

Morea 3.1 updates

Proposed updates for Morea 3.1:

  • Update to use Bootswatch using Bootstrap 5.1.3 (this makes CSS variables available).
  • Add a VERSION file so that users know what version of the Morea template they have.
  • Add an upgrade.md file to explain how to upgrade to a new version of the template.
  • Add FontAwesome
  • Define admonitions support, provide example in template, document in User Guide
    * sets the background color, maybe as a CSS variable, and maybe indents it a bit on both sides?
    * Have Tip (green), Info (blue), Warning (yellow), Danger (red) backgrounds and associated font colors.
    * augment alert with border-left-color, border-left-width, border-left-style, see https://techfolios.github.io/docs/overview
  • add anchor.js or whatever to enable links to interior pages:
    * https://www.bryanbraun.com/anchorjs/
    * https://www.bryanbraun.com/anchorjs/#pages-with-a-sticky-navbar
  • Evaluate with CI TRACS website.
  • Add a news announcement.

Fix regeneration so it doesn't error out

Currently, when editing files in a morea site, Jekyll will try to regenerate but abort with an error:

$ bundle exec jekyll serve
Configuration file: /Users/philipjohnson/github/morea-framework/morea/_config.yml
Configuration file: /Users/philipjohnson/github/morea-framework/morea/_config.yml
            Source: /Users/philipjohnson/github/morea-framework/morea
       Destination: /Users/philipjohnson/github/morea-framework/morea/_site
 Incremental build: disabled. Enable with --incremental
      Generating... 
          Conflict: The following destination is shared by multiple files.
                    The written file may end up with unexpected contents.
                    /Users/philipjohnson/github/morea-framework/morea/_site/schedule/schedule-info.js
                     - /Users/philipjohnson/github/morea-framework/morea/schedule/schedule-info.js
                     - /Users/philipjohnson/github/morea-framework/morea/schedule/schedule-info.js
                    
                    done in 1.094 seconds.
 Auto-regeneration: enabled for '/Users/philipjohnson/github/morea-framework/morea'
    Server address: http://127.0.0.1:4000/morea/
  Server running... press ctrl-c to stop.
      Regenerating: 1 file(s) changed at 2021-08-01 08:11:07
                    .idea/workspace.xml
             Error: undefined local variable or method `site' for #<Morea::MoreaGenerator:0x00007f87ec1aa290 @config={"source"=>"/Users/philipjohnson/github/morea-framework/morea", "destination"=>"/Users/philipjohnson/github/morea-framework/morea/_site", "collections_dir"=>"", "cache_dir"=>".jekyll-cache", "plugins_dir"=>"_plugins", "layouts_dir"=>"_layouts", "data_dir"=>"_data", "includes_dir"=>"_includes", "collections"=>{"posts"=>{"output"=>true, "permalink"=>"/:categories/:year/:month/:day/:title:output_ext"}}, "safe"=>false, "include"=>[".htaccess"], "exclude"=>["morea", ".sass-cache", ".jekyll-cache", "gemfiles", "Gemfile", "Gemfile.lock", "node_modules", "vendor/bundle/", "vendor/cache/", "vendor/gems/", "vendor/ruby/"], "keep_files"=>[".git", ".svn"], "encoding"=>"utf-8", "markdown_ext"=>"markdown,mkdown,mkdn,mkd,md", "strict_front_matter"=>false, "show_drafts"=>nil, "limit_posts"=>0, "future"=>false, "unpublished"=>false, "whitelist"=>[], "plugins"=>["jekyll-gist"], "markdown"=>"kramdown", "highlighter"=>"rouge", "lsi"=>false, "excerpt_separator"=>"\n\n", "incremental"=>false, "detach"=>false, "port"=>"4000", "host"=>"127.0.0.1", "baseurl"=>"/morea", "show_dir_listing"=>false, "permalink"=>"date", "paginate_path"=>"/page:num", "timezone"=>"Pacific/Honolulu", "quiet"=>false, "verbose"=>false, "defaults"=>[], "liquid"=>{"error_mode"=>"warn", "strict_filters"=>false, "strict_variables"=>false}, "kramdown"=>{"auto_ids"=>true, "toc_levels"=>[1, 2, 3, 4, 5, 6], "entity_output"=>"as_char", "smart_quotes"=>"lsquo,rsquo,ldquo,rdquo", "input"=>"GFM", "hard_wrap"=>false, "guess_lang"=>true, "footnote_nr"=>1, "show_warnings"=>false, "syntax_highlighter"=>"rouge", "syntax_highlighter_opts"=>{:default_lang=>"plaintext", :guess_lang=>true}, "coderay"=>{}}, "name"=>"ICS 199", "mathjax"=>true, "morea_theme"=>"spacelab", "morea_navbar_items"=>["Prerequisites", "Modules", "Outcomes", "Readings", "Experiences", "Assessments", "Schedule"], "logger_factory"=>{"Morea"=>"error"}, "livereload_port"=>35729, "serving"=>true, "watch"=>true, "url"=>nil, "morea_module_pages"=>[], "morea_prerequisite_pages"=>[], "morea_outcome_pages"=>[], "morea_reading_pages"=>[], "morea_experience_pages"=>[], "morea_assessment_pages"=>[], "morea_home_page"=>nil, "morea_footer_page"=>nil, "morea_page_table"=>{}, "morea_fatal_errors"=>false, "morea_dir"=>"morea", "morea_course"=>"", "morea_domain"=>"", "morea_theme_navbar_bg"=>"bg-light", "morea_overview_assessments"=>#<Morea::MoreaPage @relative_path="morea/overview-assessments.md">, "morea_overview_experiences"=>#<Morea::MoreaPage @relative_path="morea/overview-experiences.md">, "morea_overview_modules"=>#<Morea::MoreaPage @relative_path="morea/overview-modules.md">, "morea_overview_outcomes"=>#<Morea::MoreaPage @relative_path="morea/overview-outcomes.md">, "morea_overview_prerequisites"=>#<Morea::MoreaPage @relative_path="morea/overview-prerequisites.md">, "morea_overview_readings"=>#<Morea::MoreaPage @relative_path="morea/overview-readings.md">}, @summary=#<Morea::MoreaGeneratorSummary:0x00007f87ec25a5a0 @site=#<Jekyll::Site @source=/Users/philipjohnson/github/morea-framework/morea>, @total_files=62, @published_files=56, @unpublished_files=0, @morea_files=56, @non_morea_files=6, @yaml_warnings=1, @yaml_errors=0>>
             Error: Run jekyll build --trace for more information.

It would be good to fix this.

Document how to embed slideshows

It's not clear how to embed slideshows.

Create an example of how to do so and add to the Reference section of the Instructor Guide.

Experiences in unpublished modules still appear in calendar

If you unpublish a module, it should implicitly hide all of the readings, experiences, and assessents associated with that module.

Unfortunately, the Ruby code for generating the schedule-info.js file does not understand this. As a result, experiences with start dates still end up in the calendar, even if they are associated with an unpublished module.

Document JSChart

Add a section to the Instructor Guide documenting how to integrate JSCharts into a page.

Explore Liascript integration

Please do work for this task in a branch named issue-018.

Liascript is an educational courseware environment that includes a set of Markdown extensions to support quizzes and other interactive or dynamic content. (It also includes a rendering/publication mechanism, which is of less interest).

Explore whether or not we can integrate the markdown extensions provided in Liascript into Morea.

fontawesome icons no longer working

So, there was a design error in the morea template: the use of a fontawesome "kit" that I created.

I started receiving messages from Fontawesome a couple of weeks ago that I was about to go over my monthly limit of font retrievals. I assumed at that time that this was some sort of hack of my account, so I deleted the "kit" that was getting all the use.

I just realized that the problem was that every Morea site uses the same "kit".

The solution is to download the free version of fontawesome, include the file locally in the morea repo distribution, and refer to this file in the _layouts/core.html file rather than referring to the "kit".

Until that time, font awesome icons will not display in new Morea sites. (In fact, in existing Morea sites, they will never display until the source is updated locally.)

So, the steps are:

  • Download and install the free fontawesome icon kit into the morea/ site.
  • Update the documentation to explain how to patch existing Morea sites (i.e. add the fonts file, and edit the core.html file to refer to it.)

Support multiple Schedule pages

Currently, Morea does not have good support for courses in which different sections are taught on different days. A typical example is one section on MW and another on TTh. In this case, a single Schedule page is problematic since an assignment will be due on different days depending upon the section. In the past, we have tried:

  • Creating two separate Morea sites, one for each section, that differ only in the start_date associated with assignments. The problem with this approach is keeping the two sites in sync and manually changing the other site each time the first one changes. That can create a lot of maintenance overhead.
  • Removing due dates from assignments, and using some other mechanism (such as Laulima). This creates its own problems, such as when there are "suggested" dates for tasks that are not officially Laulima assignments.

To provide better support for courses with different sections on different days, Morea could provide a backwards-compatible option that enables multiple schedule pages. In this approach, there would be: a flag in the _config.yml file to enable multiple schedule pages (disabled by default or if missing from the config file). If the flag is present and enabled, then the "Schedule" link in the nav bar will be converted into a dropdown menu with two items. Each item links to a separate schedule page. One schedule page is populated with the module start/end dates and the experience start dates (as is done currently). The second schedule page is populated with module start/end dates and experience start dates as indicated by a morea_start_date2 field in the front matter.

Implementing this involves:

  1. Create a branch named issue-021 in this repository to hold the changes.
  2. Create a new top-level folder called schedule2. The contents will be just like the schedule folder, except the calendar generated will be from a file called schedule-info2.js.
  3. Update the MoreaGenerator.rb file to write out a file called schedule-info2.js when the flag for generating a second schedule is present. This should contain the appropriate entries for the second schedule.
  4. Update the _layouts/core.html file to conditionally create the dropdown menu rather than a single link to the schedule page with the config.yml flag is set.
  5. Test.
  6. Document this option in the Morea docusaurus site.
  7. Merge into master.

Relative urls in morea_url broken

Henri writes:

I have a reading that looks like:

---
morea_id: readinglecturenotes
morea_type: reading
title: "Getting Started"
published: True
morea_summary: "Course objectives, logistics, administrivia"
morea_sort_order: 8
morea_url: morea/GettingStarted/ics312_intro.pdf
morea_labels:
  - "Lecture notes"
---

[lecture notes](ics312_intro.pdf)

And the morea_url is broken. That is not not relative to anything, and gets interpreted as:

courses.ics.hawaii.edu/morea/GettingStarted/ics312_intro.pdf

syntax highlighting

@philipmjohnson first thanks for the nice framework!

I am recently struggling with the syntax highlighting while editing in framework markdown files .
that means if I take your example:

```java
public static void main(String args[]) {
  System.out.println("Hello world");
}
```

or as well

{% highlight java %}
public static void main(String args[]) {
  System.out.println("Hello world");
}
{% endhighlight %}

ends up in :

public static void main(String args[]) {
  System.out.println("Hello world");
}

so actually the result is kind of pre-formated but not highlighted at all. This occurs both with my own sites build on your template (and slightly modified) as well as with your fresh template site.
Any suggestions?
thanks and cheers
Chris

Fix warning regarding schedule-info.js

Running the system produces a warning regarding schedule-info.js:

$bundle exec jekyll serve
Configuration file: /Users/philipjohnson/github/morea-framework/morea/_config.yml
Configuration file: /Users/philipjohnson/github/morea-framework/morea/_config.yml
            Source: /Users/philipjohnson/github/morea-framework/morea
       Destination: /Users/philipjohnson/github/morea-framework/morea/_site
 Incremental build: disabled. Enable with --incremental
      Generating... 
          Conflict: The following destination is shared by multiple files.
                    The written file may end up with unexpected contents.
                    /Users/philipjohnson/github/morea-framework/morea/_site/schedule/schedule-info.js
                     - /Users/philipjohnson/github/morea-framework/morea/schedule/schedule-info.js
                     - /Users/philipjohnson/github/morea-framework/morea/schedule/schedule-info.js
                    
                    done in 0.964 seconds.

Perhaps this file should be written out to the _site/schedule directory instead of the schedule/ directory?

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.