Skip to content

Commit

Permalink
Merge pull request #34 from tomas-hartman/dev-debug
Browse files Browse the repository at this point in the history
beta 1.0
  • Loading branch information
tomas-hartman authored Dec 9, 2019
2 parents 11c5cb4 + 88c4795 commit 1899250
Show file tree
Hide file tree
Showing 19 changed files with 6,587 additions and 2,238 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules
package-lock.json
.vscode
babel-notes.md
31 changes: 24 additions & 7 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,35 @@
"version": "0.2.0",
"configurations": [
{
"name": "Listen for XDebug",
"type": "php",
"type": "chrome",
"request": "attach",
"name": "hradecns.cz_git",
"port": 9222,
"url": "http://localhost/hradecns.cz_git/",
"webRoot": "${workspaceFolder}/js/"
},

{
"type": "chrome",
"request": "launch",
"port": 9000
"name": "Calendar in Hradecns.cz_git",
"url": "http://localhost/hradecns.cz_git/",
"webRoot": "${workspaceFolder}/js/"
},

{
"name": "Launch currently open script",
"type": "chrome",
"request": "attach",
"name": "wordpress-calendar",
"port": 9222,
"url": "http://localhost/wordpress-calendar/",
"webRoot": "${workspaceFolder}/js/"
},
{
"name": "Listen for XDebug",
"type": "php",
"request": "launch",
"program": "${file}",
"cwd": "${fileDirname}",
"port": 9001
"port": 9000
}
]
}
51 changes: 51 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1 +1,52 @@
# wp-simple-calendar

https://github.com/tomas-hartman/wp-simple-calendar/

Wordpress plugin made as a lightweight and straightforward calendar solution.

Inspired by discontinued Event List Calendar made by Ryan Fait, that I originally used for a school website project (www.skolahradecns.cz).

Unlike the older one, this calendar's rendering module is based on vanilla javascript and makes no use of jQuery.

There is a full one-way compatibility with events made with Event List Calendar which makes this calendar its possible replacement.

## Installation & how to work with

1. **install wordpress**
1. **clone this repository** to your `wordpress/wp-content/plugins/` folder
2. **activate plugin** in `admin > Plugins`
3. *(recommended)* **deactivate/delete Event list calendar** (all should work fine, but there might be some incompatibility)
3. display calendar on your website using **shortcode** `[swp-mini-calendar]` (mini calendar) or `[swp-calendar-list]` (list of events)
4. **add new events** from `admin > Události`

> **Warning!** If you have previously used Event List Calendar, activation of Simple Wordpress Calendar automatically migrates all of it's data, so it can work with them. This is however one-way only proccess.
### Event settings
When you create a new event, it is obligatory to fill in its "Title" and "Date". It is optional to set "Time".

**Possible events that can be created**:
- `Simple events` *(default)*
- `Multiple day events` *(by setting "End date")*
- `Repeating events` *(by setting "Repetition")*
- `Terminated repeating events` *(by setting "End date" and "Repetition")*

> It is known issue that (way less frequent) `Repeating multiple day` and `Terminated repeating multiple day` events cannot be created [#5](https://github.com/tomas-hartman/wp-simple-calendar/issues/5).
## Feedback, bugshooting and todos

There is a good deal of features those would need more work and some other issues and bugs. Some of them are well known, some of them will emerge with further usage.

If you spot any bugs or have a feature proposition, please make an new issue at https://github.com/tomas-hartman/wp-simple-calendar/issues/.

This plugin currently do not offer any other languages than Czech and customary *continental* layout of weekdays (weeks starting on Monday). In addition, there is currently only one graphic theme of the calendar. These are some of the most desired features for possible future releases.

## Compatibility

- Should work the best with modern desktop browsers.
- Should work pretty well with mobile devices but some changes will be going on, especially on UX side [#29](https://github.com/tomas-hartman/wp-simple-calendar/issues/29).

### Legacy browser support:
- IE11
- Firefox > 60
- Chrome > 69
- Safari > 11.1
33 changes: 31 additions & 2 deletions css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@
cursor: pointer;
display: block;
width: 35px;
user-select: none;
-moz-user-select: none;
-ms-user-select: none;
}

/* Next button */
Expand All @@ -46,6 +49,9 @@
cursor: pointer;
display: block;
width: 35px;
user-select: none;
-moz-user-select: none;
-ms-user-select: none;
}

.month .next:hover, .month .prev:hover {
Expand All @@ -61,7 +67,7 @@
/* Days (1-31) */
.days {
padding: 0;
background: #bdc3c7;
/* background: #bdc3c7; */
margin: 0;
cursor: default;
}
Expand Down Expand Up @@ -111,12 +117,24 @@
box-shadow: 0 4px #9b59b6 inset;
}

.days > li {
background-color: #bdc3c7;
}

.days > li > span {
width: 100%;
height: 100%;
display: block;
}

.days > li.weekend {
background-color: rgba(127, 140, 141, 0.5);
}

.datepicker .days {
background: #bdc3c7;
}

.datepicker .days li > span:hover {
background-color: rgba(44, 62, 80, 0.220);
cursor: pointer;
Expand Down Expand Up @@ -209,6 +227,7 @@ LIST
font-weight: 400;
font-size: 15px;
margin-top: 5px;
line-height: 1.4rem;
}

#swp-cal-list-main ul{
Expand Down Expand Up @@ -247,11 +266,21 @@ span.swp-till {
background-color: #bdc3c7;
box-shadow: 4px 0px #808080, 2px 2px 0px 2px #7F8C8D;
width: 100%;
padding: 9px 5px 1px 10px;
padding: 6px 5px 1px 10px;
margin-left: 3px;
transition: 0.05s;
}

.truncate-overflow {
/* Zdrcnutí řádku. Legacy bude bez teček. */

overflow: hidden;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
}


#swp-cal-list-main li .swp-list-title a:hover {
box-shadow: none;
background-color: #bdc3c7;
Expand Down
55 changes: 0 additions & 55 deletions js-babel/ajax.js

This file was deleted.

Loading

0 comments on commit 1899250

Please sign in to comment.