Skip to content

Commit

Permalink
Merge branch 'bootstrap-ui'
Browse files Browse the repository at this point in the history
  • Loading branch information
craigk5n committed Mar 4, 2022
2 parents 69d22af + a06b8b3 commit 36358ad
Show file tree
Hide file tree
Showing 368 changed files with 17,411 additions and 40,932 deletions.
13 changes: 13 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: 2
updates:

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"

# Maintain dependencies for Composer
- package-ecosystem: "composer"
directory: "/"
schedule:
interval: "daily"
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,7 @@ includes/htmlarea
includes/settings.php
.DS_Store
mysql-data
*.sha
vendor
*.orig
*.save
146 changes: 146 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
# Makefile for copying files downloaded using composer into the proper location
# for use with WebCalendar.
# We onlt copy the min number of files required from the vendor directory.
# Also, compute the SHA hash to use with the integrity tag.
# We don't want WebCalendar releases to bundle every single file in the vendor directory.
# Also, composer dependency management sucks at asset management.

PHPMAILER_DIR = includes/classes/phpmailer
PHPMAILER_VENDOR_DIR = vendor/phpmailer/phpmailer/src

BOOTSTRAP_ICON_DIR = images/bootstrap-icons
BOOTSTRAP_ICON_VENDOR_DIR = vendor/twbs/bootstrap-icons/icons

_DEFAULT: _phpmailer includes/load_assets.php \
_ICONS

_phpmailer: $(PHPMAILER_DIR)/PHPMailer.php \
$(PHPMAILER_DIR)/Exception.php \
$(PHPMAILER_DIR)/OAuth.php \
$(PHPMAILER_DIR)/POP3.php \
$(PHPMAILER_DIR)/SMTP.php

$(PHPMAILER_DIR)/PHPMailer.php: $(PHPMAILER_VENDOR_DIR)/PHPMailer.php
cp $< $@

$(PHPMAILER_DIR)/Exception.php: $(PHPMAILER_VENDOR_DIR)/Exception.php
cp $< $@

$(PHPMAILER_DIR)/OAuth.php: $(PHPMAILER_VENDOR_DIR)/OAuth.php
cp $< $@

$(PHPMAILER_DIR)/POP3.php: $(PHPMAILER_VENDOR_DIR)/POP3.php
cp $< $@

$(PHPMAILER_DIR)/SMTP.php: $(PHPMAILER_VENDOR_DIR)/SMTP.php
cp $< $@

_ICONS: \
$(BOOTSTRAP_ICON_DIR)/printer.svg \
$(BOOTSTRAP_ICON_DIR)/search.svg \
$(BOOTSTRAP_ICON_DIR)/arrow-right-circle.svg \
$(BOOTSTRAP_ICON_DIR)/arrow-left-circle.svg \
$(BOOTSTRAP_ICON_DIR)/arrow-up-short.svg \
$(BOOTSTRAP_ICON_DIR)/arrow-down-short.svg \
$(BOOTSTRAP_ICON_DIR)/plus-circle.svg \
$(BOOTSTRAP_ICON_DIR)/rss-fill.svg \
$(BOOTSTRAP_ICON_DIR)/circle-fill.svg \
$(BOOTSTRAP_ICON_DIR)/exclamation-triangle-fill.svg \
$(BOOTSTRAP_ICON_DIR)/question-circle-fill.svg \
$(BOOTSTRAP_ICON_DIR)/arrow-90deg-up.svg \
$(BOOTSTRAP_ICON_DIR)/dash-circle.svg \
$(BOOTSTRAP_ICON_DIR)/check-circle.svg \
$(BOOTSTRAP_ICON_DIR)/trash.svg \
$(BOOTSTRAP_ICON_DIR)/key-fill.svg

$(BOOTSTRAP_ICON_DIR)/printer.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/printer.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/search.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/search.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/arrow-right-circle.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/arrow-right-circle.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/arrow-left-circle.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/arrow-left-circle.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/arrow-up-short.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/arrow-up-short.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/arrow-down-short.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/arrow-down-short.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/plus-circle.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/plus-circle.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/rss-fill.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/rss-fill.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/circle-fill.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/circle-fill.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/exclamation-triangle-fill.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/exclamation-triangle-fill.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/question-circle-fill.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/question-circle-fill.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/arrow-90deg-up.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/arrow-90deg-up.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/dash-circle.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/dash-circle.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/check-circle.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/check-circle.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/trash.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/trash.svg
cp $< $@

$(BOOTSTRAP_ICON_DIR)/key-fill.svg: $(BOOTSTRAP_ICON_VENDOR_DIR)/key-fill.svg
cp $< $@

includes/load_assets.php: \
pub/bootstrap.min.css \
pub/bootstrap.min.css.sha \
pub/bootstrap.bundle.min.js \
pub/bootstrap.bundle.min.js.sha \
pub/jquery.min.js \
pub/jquery.min.js.sha
echo '<?php' > $@
echo '// Auto-generated by make. Do not hand-edit.' >> $@
echo '// See Makefile in source for details..' >> $@
echo -n '// Last updated: ' >> $@
date >> $@
echo "XASSETS =" | tr X '\044' >> $@
echo -n ' _<link rel="stylesheet" href="pub/bootstrap.min.css" integrity="sha384-' | tr _ '\047' >> $@
cat pub/bootstrap.min.css.sha | tr -d '\012' >> $@
echo '">_ .' | tr _ '\047' >> $@
echo -n ' _<script src="pub/jquery.min.js" integrity="sha384-' | tr _ '\047' >> $@
cat pub/jquery.min.js.sha | tr -d '\012' >> $@
echo '"></script>_ .' | tr _ '\047' >> $@
echo -n ' _<script src="pub/bootstrap.bundle.min.js" integrity="sha384-' | tr _ '\047' >> $@
cat pub/bootstrap.bundle.min.js.sha | tr -d '\012' >> $@
echo '"></script>_ .' | tr _ '\047' >> $@
echo ' "\\n";' >> $@
echo '?>' >> $@

pub/bootstrap.min.css: vendor/twbs/bootstrap/dist/css/bootstrap.min.css
cp $< $@

pub/bootstrap.min.css.sha: pub/bootstrap.min.css
sha384sum $< | head -c 96 | xxd -r -p | base64 > $@

pub/bootstrap.bundle.min.js: vendor/twbs/bootstrap/dist/js/bootstrap.bundle.min.js
cp $< $@

pub/bootstrap.bundle.min.js.sha: pub/bootstrap.bundle.min.js
sha384sum $< | head -c 96 | xxd -r -p | base64 > $@

pub/jquery.min.js: vendor/components/jquery/jquery.min.js
cp $< $@

pub/jquery.min.js.sha: pub/jquery.min.js
sha384sum $< | head -c 96 | xxd -r -p | base64 > $@

16 changes: 14 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
WebCalendar README
------------------

Project Home Page: http://k5n.us/wp/webcalendar/
Project Home Page: https://www.k5n.us/webcalendar/
Project Owner: Craig Knudsen, &#99;&#114;&#97;&#105;&#103;&#64;&#107;&#53;&#110;&#46;&#117;&#115;
Documentation:
- [System Administrator's Guide](http://htmlpreview.github.io/?https://github.com/craigk5n/webcalendar/blob/master/docs/WebCalendar-SysAdmin.html) (Installation instructions, FAQ)
Expand All @@ -13,7 +13,19 @@ Developer Resources:
- [WebCalendar-Database.html](http://htmlpreview.github.io/?https://github.com/craigk5n/webcalendar/blob/master/docs/WebCalendar-Database.html)
- [WebCalendar-DeveloperGuide.html](http://htmlpreview.github.io/?https://github.com/craigk5n/webcalendar/blob/master/docs/WebCalendar-DeveloperGuide.html)

## Setting up a docker dev environment
## Installation Instructions

After unzipping your files (or transferring the files to your hosting
provider, you will need to go to the web-based install script.
If your files are installed in a "webcalendar" folder under your parent
web server document root, you can access the script by going to:

https://yourserverhere/webcalendar/

(Obviously, put the correct server name in above.) The toplevel URL will
automatically redirect to the installation wizard.

## Setting Up a Docker Dev Environment

You can setup a docker environment with PHP 7.4 and MariaDb with a few
steps.
Expand Down
5 changes: 5 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# WebCalendar Security

## Reporting Security Concerns

Contact the project using the [email protected] email address.
18 changes: 6 additions & 12 deletions TODO
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
Things to do as part of the WebCalendar 1.3 development cycle
Things to do as part of the WebCalendar 2.X development cycle

Com
ple Description
te?
--- -------------------------------------

[ ] JavaScript code scanning on Github.
CodeQL support javascript:
https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning
[ ] PHP code scanning on Github.
Psalm supports PHP code scanning: https://github.com/vimeo/psalm
[ ] Better handling of large numbers of users (1000+).
We have one user who claims the JS chokes the browser with 1000+
users when you press the "Select..." button
[ ] Added cal_fullname (or cal_display_name) column to webcal_user
and webcal_nonuser_cals so nonuser cals do not need to specify
first and last name (since it does not usually make sense).
[X] Add support for category colors
[ ] Setup wizard (web-based) that would guide the admin through setting
up what is now in System Settings and explain why they would want
to use any particular option.
It could start with primary use (Home Single User, Small Biz,
Large Enterprise, Events Calendar, etc...)
[ ] Add email notification for submission of new public events
(ideally, multiple email recipients will be possible)
[ ] Allowing nonuser public calendar to have anonymous users submit
Expand Down Expand Up @@ -46,14 +46,8 @@ Here are some other ideas for the next or perhaps later releases:
[ ] Ability to support a reservation system (for either a single resource
or multiple resources) as the primary use. Most likely, this would
involve reserving an entire day rather than a time period.
[ ] Java-based tool (web start) for monitoring and approving new
public events (would run in background until new event is submitted,
then popup for accept/reject)
[ ] Admin tool for importing a large number of users (CSV, tab-delimeted, etc.)
(Someone has contributed a patch for this.)
[ ] Use SyncML to sync WebCalendar with SyncML-supported devices (PocketPC)
[ ] Create Google Desktop plug-in that will allow WebCalendar events to
be indexed so that they show up in Google Desktop search results.
[ ] Create AJAX-based interface. The existing web service functions could
be re-used for this.
[ ] Don't allow the last admin user to be deleted
Expand Down
Loading

0 comments on commit 36358ad

Please sign in to comment.