Skip to content

Commit 710f082

Browse files
authored
Merge pull request #790 from ucfopen/dev/v3-2-0
Release 3.2.0
2 parents d19ef66 + bdf782d commit 710f082

39 files changed

+1342
-964
lines changed

.env

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ PHPALLY_SUGGESTION_RULES="
5858
AnchorLinksToSoundFilesNeedTranscripts,
5959
AnchorSuspiciousLinkText,
6060
ContentTooLong,
61+
IframeNotHandled,
6162
InputImageNotDecorative,
6263
NoHeadings,
6364
ObjectTagDetected,
@@ -79,6 +80,63 @@ EASY_FIX_RULES="
7980
ParagraphNotUsedAsHeader,
8081
ImageAltNotPlaceholder,
8182
"
83+
# Rules that impact people with visual disabilities. Comma-separated list of rule IDs.
84+
VISUAL_RULES="
85+
AnchorMustContainText,
86+
AnchorSuspiciousLinkText,
87+
BaseFontIsNotUsed,
88+
CssTextHasContrast,
89+
CssTextStyleEmphasize,
90+
FontIsNotUsed,
91+
HeadersHaveText,
92+
HeadingsInOrder,
93+
ImageAltIsDifferent,
94+
ImageAltIsTooLong,
95+
ImageAltNotEmptyInAnchor,
96+
ImageAltNotPlaceholder,
97+
ImageHasAlt,
98+
ImageHasAltDecorative,
99+
ImageHasLongDescription,
100+
InputImageNotDecorative,
101+
NoHeadings,
102+
ObjectTagDetected,
103+
ParagraphNotUsedAsHeader,
104+
PreShouldNotBeUsedForTabularValues,
105+
TableDataShouldHaveTableHeader,
106+
TableHeaderShouldHaveScope,
107+
"
108+
# Rules that impact people with auditory disabilities. Comma-separated list of rule IDs.
109+
AUDITORY_RULES="
110+
AnchorLinksToMultiMediaRequireTranscript,
111+
AnchorLinksToSoundFilesNeedTranscripts,
112+
ObjectMustContainText,
113+
ObjectTagDetected,
114+
VideoCaptionsMatchCourseLanguage,
115+
VideoEmbedCheck,
116+
VideoProvidesCaptions,
117+
VideosEmbeddedOrLinkedNeedCaptions,
118+
VideosEmbeddedOrLinkedNeedCaptions,
119+
VideosHaveAutoGeneratedCaptions,
120+
"
121+
# Rules that impact people with cognitive disabilities. Comma-separated list of rule IDs.
122+
COGNITIVE_RULES="
123+
BaseFontIsNotUsed,
124+
BlinkIsNotUsed,
125+
ContentTooLong,
126+
DocumentReadingDirection,
127+
FontIsNotUsed,
128+
HeadingsInOrder,
129+
MarqueeIsNotUsed,
130+
NoHeadings,
131+
ObjectTagDetected,
132+
ParagraphNotUsedAsHeader,
133+
TableDataShouldHaveTableHeader,
134+
TableHeaderShouldHaveScope,
135+
"
136+
# Rules that impact people with motor disabilities. Comma-separated list of rule IDs.
137+
MOTOR_RULES="
138+
ObjectTagDetected,
139+
"
82140
###< phpally ###
83141

84142
###> i18n ###

.env.local.example

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
APP_ENV=prod
33

44
###> doctrine/doctrine-bundle ###
5-
DATABASE_URL=mysql://root:root@127.0.0.1:3306/udoit3
5+
DATABASE_URL=mysql://root:root@db:3306/udoit3
66

77
###> base url ###
88
# Base URL for client callbacks
9-
BASE_URL="https://localhost/udoit/public"
9+
BASE_URL="https://127.0.0.1:8000"
1010
###> base url ###
1111

1212
APP_LMS=canvas

.github/workflows/udoit.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
fail-fast: false
1010
matrix:
1111
operating-system: [ubuntu-latest]
12-
php-versions: ['7.4', '8.0']
12+
php-versions: ['8.1']
1313
steps:
1414
- name: Checkout
1515
uses: actions/checkout@v2

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
FROM php:7.4-fpm
2-
ARG ENVIORNMENT_TYPE
2+
ARG ENVIRONMENT_TYPE
33

44
#Install dependencies and php extensions
55
RUN apt-get update && apt-get install -y \
@@ -18,7 +18,7 @@ RUN apt-get update && apt-get install -y \
1818
&& docker-php-ext-install pdo_pgsql
1919

2020
#Install AWS CLI v2
21-
RUN if [ "$ENVIORNMENT_TYPE" != "local" ] ;then \
21+
RUN if [ "$ENVIRONMENT_TYPE" != "local" ] ;then \
2222
curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" \
2323
&& unzip awscliv2.zip \
2424
&& ./aws/install\

HEROKU.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Click the Heroku button and follow the instructions below:
1717
* `canvas` if you are using the Canvas LMS.
1818
* `d2l` if you are using the D2l Brightspace LMS.
1919
5. Fill out the `BASE_URL` field with `https://yourapp.herokuapp.com`. (Replace 'yourapp' with the name you gave in step 1.2.)
20-
6. Fill out the `JWK_BASE_URL` field with the URL to your LMS. The default value works for instructure hosted instances of Canvas, but will need to be modified according to the LMS and host.
20+
6. Fill out the `JWK_BASE_URL` field with the URL to your LMS. The default value works for instructure hosted instances of Canvas, but will need to be modified if your JWK configuration is hosted at a different domain than `iss`.
2121
7. Click the Deploy button and wait for the process to complete.
2222

2323
### Step 2: Database Migration and Setup

INSTALL.md

Lines changed: 45 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ We strongly recommend source code should be managed through Git. The benefit of
1919
## Docker
2020
We provide a fast and simple way of setting up a local UDOIT instance through the use of docker containers. To set up the docker containers, you must first install [Docker](https://docs.docker.com/get-docker/) and [Docker Compose](https://docs.docker.com/compose/install/). Then, simply run the following command from within the UDOIT directory:
2121

22-
docker-compose up --build
22+
docker-compose up -d
2323

2424
Once the containers are up and running, you can access the php container by calling the command:
2525

@@ -38,31 +38,46 @@ Once you have set up the containers in this way, you will still need to follow t
3838
## Configuring your Web Server
3939
The details of configuring a web server with PHP are out of the scope of this README. You should configure your web server to point to UDOIT's "public" folder as the web root folder. Doing this will hide the configuration and source files so that they are not web accessible. It will also clean up your URL structure so that you don't need to include the "public" folder in any of the URLs to UDOIT.
4040

41-
If you are setting up a local UDOIT instance through Docker, you can simplify this step and quickly setup a server by calling the following command from within the php container:
41+
If you are setting up a local UDOIT instance through Docker, you can simplify this step and quickly setup a server by calling the following commands from within the php container:
4242

43+
docker exec -it udoit_php_1 /bin/bash
4344
symfony server:ca:install
45+
symfony serve -d
4446

45-
Followed by the following command:
47+
Security Note: Do not use the commands above for production installations. Use software such as [Apache](https://httpd.apache.org) or [NGINX](https://nginx.org).
4648

47-
symfony serve -d
49+
SSL Issues: It is important to note that most browsers will automatically block unsigned certificates, and the tool might fail to load with the message that the website might be down or have moved to a new location. If this happens to you after going through the rest of the instructions, you can bypass this warning by opening the specified url in a new tab, granting the browser permission to access the webpage, and then going back to where the UDOIT tool has been integrated and refreshing the page.
4850

49-
It is important to note that most browsers will automatically block unsigned certificates, and the tool might fail to load with the message that the website might be down or have moved to a new location. If this happens to you after going through the rest of the instructions, you can bypass this warning by opening the specified url in a new tab, granting the browser permission to access the webpage, and then going back to where the UDOIT tool has been integrated and refreshing the page.
51+
> If you are running UDOIT in Docker, you will need do this each time you start the docker container.
5052
5153
## Installing Composer Dependencies
52-
UDOIT uses Composer to install PHP dependencies. Installing Composer is out of the scope of this README, but here is some documentation on [Composer Installation](https://getcomposer.org/doc/00-intro.md#introduction).
54+
UDOIT uses Composer to install PHP dependencies. If you are using Docker, it will already be installed inside the PHP container. To install the required PHP dependencies, enter the PHP container with:
55+
56+
docker exec -it udoit_php_1 /bin/bash
57+
58+
Then, install the dependencies:
59+
60+
composer install --no-dev
5361

54-
Assuming you have Composer installed, navigate to your UDOIT directory in the CLI and run this command:
62+
If you're not using Docker, follow the upstream documentation on [Composer Installation](https://getcomposer.org/download/) to install `composer.phar` into the project root, then run the following:
5563

5664
php composer.phar install --no-dev
5765

66+
> Remove the `--no-dev` flag if you wish to use `APP_ENV=dev` below.
67+
5868
## .ENV Setup
5969
UDOIT uses a `.env` file for storing configuration. Local configuration such as database information and URLs should be stored in a `.env.local` file that is NOT tracked in Git.
70+
71+
> These changes should be made outside any of the Docker containers.
72+
6073
1. Copy the file `.env.local.example` to `.env.local`.
61-
2. Change `APP_ENV` to
62-
* `dev` if you are setting up a development environment
63-
* `prod` if you are setting up a production server
74+
```
75+
cp .env.local.example .env.local
76+
```
77+
2. Leave `APP_ENV` set to `prod`
78+
> If you are setting up a development environment, set this to `dev` and follow the steps in [Installing Composer Dependencies](#installing-composer-dependencies) without the `--no-dev` flag to obtain all of the development packages.
6479
3. Add your database information to this `DATABASE_URL` variable.
65-
4. Add the `BASE_URL`, which is the full URL to reach the `public` folder of UDOIT. (i.e. https://udoit3.ciditools.com)
80+
4. Add the `BASE_URL`, which is the full URL to reach the `public` folder of UDOIT. (i.e. https://udoit3.ciditools.com) WITHOUT the trailing slash.
6681
5. Set `APP_LMS` to the name of your LMS.
6782
* `canvas` if you are using the Canvas LMS.
6883
* `d2l` if you are using the D2l Brightspace LMS.
@@ -71,6 +86,12 @@ UDOIT uses a `.env` file for storing configuration. Local configuration such as
7186
## Database Setup
7287
While UDOIT is configured to use MySQL or MariaDB by default, Symfony can be configured to work with other databases as well. See the Symfony documentation for details.
7388

89+
> If you are running UDOIT in Docker, you don't need to install PHP on your system. You can run
90+
>
91+
> docker exec -it udoit_php_1 /bin/bash
92+
>
93+
> and then run the commands below inside the Docker container.
94+
7495
You can create your database manually, or use `Symfony` to create the database with this command:
7596

7697
php bin/console doctrine:database:create
@@ -87,12 +108,20 @@ If you are operating in a production environment you will need to generate the d
87108

88109
php bin/console cache:warmup --env=prod
89110

90-
## Javascript
91-
UDOIT uses `node` and `yarn` to compile the javascript. Instructions for installing Node and Yarn are out of the scope of this README. TO install the javascript dependencies run the command:
111+
## JavaScript
112+
UDOIT uses [node](https://nodejs.org) and [yarn](https://yarnpkg.com/) to compile the JavaScript. Instructions for installing Node and Yarn are out of the scope of this README.
113+
114+
> If you are running UDOIT in Docker, you don't need to install Node or Yarn on your system. Run
115+
>
116+
> docker exec -it udoit_php_1 /bin/bash
117+
>
118+
> and then run the following commands inside the Docker container.
119+
120+
To install the JavaScript dependencies run the command:
92121

93122
yarn install
94123

95-
To build the javascript files for production, run the command:
124+
To build the JavaScript files for production, run the command:
96125

97126
yarn build
98127

@@ -103,9 +132,9 @@ However, UDOIT does have one URL that is publicly available outside of the LMS.
103132

104133
<BASE_URL>/lti/config
105134

106-
For example, if you are setting this up on your local computer it may look like:
135+
For example, if you are setting this up on your local computer via Docker, it may look like:
107136

108-
https://udoit.local/lti/config
137+
https://localhost:8000/lti/config
109138

110139
## Configuring Your LMS
111140
You will need to complete the steps in the [INSTALL_CANVAS.md](INSTALL_CANVAS.md) or [INSTALL_D2L.md](INSTALL_D2L.md) to configure UDOIT to work within your LMS.

app.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@
2727
"value": "https://your.herokuapp.com"
2828
},
2929
"JWK_BASE_URL": {
30-
"description": "Full URL to your LMS. Default value works for cloud hosted Canvas.",
31-
"value": "https://canvas.instructure.com/"
30+
"description": "Overrides `iss` to use an alternative url for JWK. Leave empty if using cloud hosted Canvas.",
31+
"value": ""
3232
},
3333
"HEROKU_TIMEOUT": {
3434
"description": "Web requests time out at 30 seconds causing the app to crash. Value should be significantly less than 30 to prevent this.",

assets/js/Components/Admin/AdminApp.js

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import React from 'react'
2-
import '@instructure/canvas-theme'
32
import AdminHeader from './AdminHeader'
43
import CoursesPage from './CoursesPage'
54
import ReportsPage from './ReportsPage'
@@ -27,7 +26,7 @@ class AdminApp extends React.Component {
2726
this.settings.accountId = accountIds.shift()
2827
}
2928
}
30-
29+
3130
this.state = {
3231
courses: {},
3332
filters: {
@@ -133,7 +132,7 @@ class AdminApp extends React.Component {
133132

134133
loadCourses(filters, isMounted) {
135134
const api = new Api(this.settings)
136-
135+
137136
api.getAdminCourses(filters)
138137
.then((response) => response.json())
139138
.then((data) => {
@@ -164,13 +163,13 @@ class AdminApp extends React.Component {
164163
clearMessages = () => {
165164
this.messages = [];
166165
}
167-
166+
168167
handleFilter(newFilter) {
169168
const filters = Object.assign(this.state.filters, newFilter)
170169
this.setState({ filters }, () => {
171170
this.loadCourses(this.state.filters, true)
172171
})
173-
172+
174173
}
175174

176175
handleCourseUpdate(course) {
@@ -213,4 +212,4 @@ class AdminApp extends React.Component {
213212
}
214213
}
215214

216-
export default AdminApp
215+
export default AdminApp

assets/js/Components/App.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ class App extends React.Component {
241241
// resize containing iframe height
242242
resizeFrame(){
243243
let default_height = document.body.scrollHeight + 50;
244-
default_height = default_height > 500 ? default_height : 500;
244+
default_height = default_height > 1000 ? default_height : 1000;
245245

246246
// IE 8 & 9 only support string data, so send objects as string
247247
parent.postMessage(JSON.stringify({

assets/js/Components/Constants.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ export const issueRuleIds = [
1313
"FontIsNotUsed",
1414
"HeadersHaveText",
1515
"HeadingsInOrder",
16+
"IframeNotHandled",
1617
"ImageAltIsDifferent",
1718
"ImageAltIsTooLong",
1819
"ImageAltNotEmptyInAnchor",

0 commit comments

Comments
 (0)