From 105d8b6bb8bd0be186c14b1b990c156aa3c93ec0 Mon Sep 17 00:00:00 2001 From: Knight Tan Date: Fri, 16 Oct 2020 22:02:03 +0800 Subject: [PATCH 001/522] change save to download and display cert permalink for #1379 --- templates/content-certificate.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/templates/content-certificate.php b/templates/content-certificate.php index 8e45e356de..0724e1d689 100644 --- a/templates/content-certificate.php +++ b/templates/content-certificate.php @@ -44,7 +44,7 @@
get( 'id' ) ) === $cert->get( 'db_post_type' ) ) : ?> @@ -54,6 +54,13 @@ + + + +
From 08afa89a26c5c20fbc81b9defe5c6128c6f7641a Mon Sep 17 00:00:00 2001 From: Knight Tan Date: Fri, 16 Oct 2020 22:05:55 +0800 Subject: [PATCH 002/522] remove unwantedy style and clean up --- templates/content-certificate.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/content-certificate.php b/templates/content-certificate.php index 0724e1d689..acb4b9568c 100644 --- a/templates/content-certificate.php +++ b/templates/content-certificate.php @@ -55,10 +55,10 @@ - + From de0b1c1475bf16639435351e0682d5deaad5bbb9 Mon Sep 17 00:00:00 2001 From: Knight Tan Date: Fri, 16 Oct 2020 22:56:10 +0800 Subject: [PATCH 003/522] fixed style --- templates/content-certificate.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/content-certificate.php b/templates/content-certificate.php index acb4b9568c..4c6b670a2f 100644 --- a/templates/content-certificate.php +++ b/templates/content-certificate.php @@ -54,9 +54,9 @@ - + - + From 7e93fb0bd389c5fa2112374e02b44d7cbcd6a318 Mon Sep 17 00:00:00 2001 From: Knight Tan Date: Mon, 19 Oct 2020 22:50:01 +0800 Subject: [PATCH 004/522] convert from span into input --- templates/content-certificate.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/templates/content-certificate.php b/templates/content-certificate.php index 4c6b670a2f..f9698fa0f2 100644 --- a/templates/content-certificate.php +++ b/templates/content-certificate.php @@ -55,10 +55,7 @@ - - - - + From 9a6532a5d9f66b8056084a66a3b4919b3896d295 Mon Sep 17 00:00:00 2001 From: Knight Tan Date: Wed, 21 Oct 2020 22:29:32 +0800 Subject: [PATCH 005/522] UX improvement to url field --- templates/content-certificate.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/templates/content-certificate.php b/templates/content-certificate.php index f9698fa0f2..398635761e 100644 --- a/templates/content-certificate.php +++ b/templates/content-certificate.php @@ -55,7 +55,7 @@ - + @@ -65,3 +65,12 @@ + From eb08c3c9a2bfe2ef301132c1f58e6e3a1ff60297 Mon Sep 17 00:00:00 2001 From: Knight Tan Date: Fri, 23 Oct 2020 21:19:29 +0800 Subject: [PATCH 006/522] change it into inline js function --- templates/content-certificate.php | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/templates/content-certificate.php b/templates/content-certificate.php index 398635761e..40ee4df8de 100644 --- a/templates/content-certificate.php +++ b/templates/content-certificate.php @@ -55,7 +55,7 @@ - + @@ -65,12 +65,3 @@ - From 2978bbed8c1678437a465dfdacbb577f4748dd3e Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 13 Mar 2023 00:42:58 +0530 Subject: [PATCH 007/522] Added Object (Lesson) Favorite functionality --- includes/class-llms-loader.php | 2 + .../class.llms.controller.favorites.php | 160 +++++++++++++++++ ...ass.llms.controller.lesson.progression.php | 2 +- includes/functions/llms.functions.person.php | 18 ++ includes/llms.template.functions.php | 13 ++ includes/llms.template.hooks.php | 3 +- includes/models/model.llms.student.php | 163 ++++++++++++++++++ templates/course/favorite.php | 58 +++++++ 8 files changed, 417 insertions(+), 2 deletions(-) create mode 100644 includes/controllers/class.llms.controller.favorites.php create mode 100644 templates/course/favorite.php diff --git a/includes/class-llms-loader.php b/includes/class-llms-loader.php index eae5d74761..e8d79430d0 100644 --- a/includes/class-llms-loader.php +++ b/includes/class-llms-loader.php @@ -232,6 +232,7 @@ public function autoload( $class ) { * Removed loading of class files that don't instantiate their class in favor of autoloading. * @since 6.4.0 Included `LLMS_Shortcodes` before `LLMS_Controller_Orders`. * @since 7.0.0 Include `LLMS_Controller_Checkout`. + * @since [version] Include `LLMS_Controller_Favorite`. * * @return void */ @@ -285,6 +286,7 @@ public function includes() { require_once LLMS_PLUGIN_DIR . 'includes/controllers/class-llms-controller-awards.php'; require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.certificates.php'; require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.lesson.progression.php'; + require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.favorites.php'; require_once LLMS_PLUGIN_DIR . 'includes/controllers/class-llms-controller-checkout.php'; // Added out of alpha order to preserve action load order. require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.orders.php'; require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.quizzes.php'; diff --git a/includes/controllers/class.llms.controller.favorites.php b/includes/controllers/class.llms.controller.favorites.php new file mode 100644 index 0000000000..5ec7d4661f --- /dev/null +++ b/includes/controllers/class.llms.controller.favorites.php @@ -0,0 +1,160 @@ +get_object_id_from_form_data( 'favorite' ); + $object_type = llms_filter_input( INPUT_POST, 'type' ); + + if ( is_null( $object_id ) ) { + return; + } + + /** + * Filter to modify the user id instead of current logged in user id. + * + * @param int $user_id User id to mark lesson as favorite. + * + * @since [version] + */ + $user_id = apply_filters( 'llms_object_favorite_user_id', get_current_user_id() ); + + do_action( 'llms_trigger_object_favorite', $user_id, $object_id, $object_type ); + + } + + /** + * Mark Object as unfavorite + * + * + Unfavorite Object form post. + * + Marks Object as Unfavorite. + * + * @since [version] + * + * @return void + */ + public function handle_unfavorite_form() { + + $lesson_id = $this->get_object_id_from_form_data( 'unfavorite' ); + $object_type = llms_filter_input( INPUT_POST, 'type' ); + + if ( is_null( $lesson_id ) ) { + return; + } + + /** + * Filter to modify the user id instead of current logged in user id. + * + * @param int $user_id User id to mark object as unfavorite. + * + * @since [version] + */ + $user_id = apply_filters( 'llms_object_unfavorite_user_id', get_current_user_id() ); + + // Mark unfavorite. + llms_mark_unfavorite( $user_id, $object_id, $object_type ); + + } + + /** + * Handle favoriting of object via `llms_trigger_object_favorite` action + * + * @since [version] + * + * @param int $user_id User ID. + * @param int $object_id Object ID. + * @param string $object_type Object description string (Lesson, Course or Instructor). + * @param array $args Optional arguments. + * @return void + */ + public function mark_favorite( $user_id, $object_id, $object_type = '', $args = array() ) { + + if ( llms_allow_lesson_completion( $user_id, $object_id, $object_type, $args ) ) { + + llms_mark_favorite( $user_id, $object_id, $object_type ); + + } + + } + +} + +return new LLMS_Controller_Favorite(); diff --git a/includes/controllers/class.llms.controller.lesson.progression.php b/includes/controllers/class.llms.controller.lesson.progression.php index a5f19d1fd0..de703a995f 100644 --- a/includes/controllers/class.llms.controller.lesson.progression.php +++ b/includes/controllers/class.llms.controller.lesson.progression.php @@ -44,7 +44,7 @@ public function __construct() { * * @since 3.29.0 * - * @param tring $action Form action, either "complete" or "incomplete". + * @param String $action Form action, either "complete" or "incomplete". * @return int|null Returns `null` when either required post fields are missing or if the lesson_id is non-numeric, int (lesson id) on success. */ private function get_lesson_id_from_form_data( $action ) { diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index 4044c66447..e73f93b791 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -330,10 +330,28 @@ function llms_is_user_enrolled( $user_id, $product_id, $relation = 'all', $use_c * @return boolean */ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'unspecified' ) { + // die('minus one'); $student = new LLMS_Student( $user_id ); return $student->mark_complete( $object_id, $object_type, $trigger ); } +/** + * Mark an object as favorite + * + * @since [version] + * + * @see LLMS_Student->mark_favorite() + * + * @param int $user_id WP User ID. + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param int $object_type Object type [lesson|section|course|track]. + * @return boolean + */ +function llms_mark_favorite( $user_id, $object_id, $object_type ) { + $student = new LLMS_Student( $user_id ); + return $student->mark_favorite( $object_id, $object_type ); +} + /** * Mark a lesson, section, course, or track as incomplete * diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index f85b10d3c2..c663b1d87c 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -385,6 +385,19 @@ function lifterlms_template_single_parent_course() { } } +/** + * Favorite Lesson Template Include + * + * @return void + */ +if ( ! function_exists( 'lifterlms_template_single_favorite' ) ) { + + function lifterlms_template_single_favorite() { + + llms_get_template( 'course/favorite.php' ); + } +} + /** * Complete Lesson Link Template Include * diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index ca205fb744..2203ccd750 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -7,7 +7,7 @@ * @package LifterLMS/Hooks * * @since 1.0.0 - * @version 6.0.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -48,6 +48,7 @@ * @since Unknown */ add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_parent_course', 10 ); +add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_favorite', 10 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_video', 20 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_audio', 20 ); diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index f72f838faa..f18dfcca1c 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1253,6 +1253,30 @@ private function insert_incompletion_postmeta( $object_id, $trigger = 'unspecifi } + /** + * Add student postmeta data when lesson is favorited + * + * @param int $object_id WP Post ID of the lesson + * @param string $trigger String describing the reason for mark completion + * @return boolean + * @since [version] + * @version [version] + */ + private function insert_favorite_postmeta( $object_id, $trigger = 'unspecified' ) { + + // Add info to the user postmeta table. + $user_metadatas = array( + '_is_favorite' => 'yes', + '_completion_trigger' => $trigger, + ); + + $update = llms_update_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); + + // Returns an array with errored keys or true on success. + return is_array( $update ) ? false : true; + + } + /** * Add student postmeta data for enrollment into a course or membership * @@ -1841,4 +1865,143 @@ private function update_completion_status( $status, $object_id, $object_type, $t } + /** + * Determine if the student has favorited a lesson + * + * @param int $object_id WP Post ID of a course or lesson or section or the term id of the track + * @param string $type Object type (course, lesson, section, or track) + * @return boolean + * @since [version] + * @version [version] + */ + public function is_favorite( $object_id, $object_type = 'course' ) { + + $query = new LLMS_Query_User_Postmeta( + array( + 'types' => 'favorites', + 'include_post_children' => false, + 'user_id' => $this->get_id(), + 'post_id' => $object_id, + 'per_page' => 1, + ) + ); + + $ret = $query->has_results(); + + return apply_filters( 'llms_is_' . $object_type . '_favorite', $ret, $object_id, $object_type, $this ); + + } + + /** + * Mark a lesson, section, course, or track complete for the given user + * + * @param int $object_id WP Post ID of the lesson, section, course, or track + * @param string $object_type object type [lesson|section|course|track] + * @param string $trigger String describing the reason for marking complete + * @return boolean + * + * @see llms_mark_favorite() calls this function without having to instantiate the LLMS_Student class first + * + * @since [version] + * @version [version] + */ + public function mark_favorite( $object_id, $object_type ) { + + // Short circuit if it's already favorited. + if ( $this->is_favorite( $object_id, $object_type ) ) { + return true; + } + + return $this->update_favorite_status( 'favorite', $object_id, $object_type ); + + } + + /** + * Update the favorite status of a track, course, section, or lesson for the current student + * + * Triggers actions for favorite/unfavorite. + * + * Inserts / updates necessary user postmeta data. + * + * @since [version] + * @since 4.2.0 Use filterable functions to determine if the object is completable. + * Added filter to allow customization of object parent data. + * + * @param string $status New status to update to, either "complete" or "incomplete". + * @param int $object_id WP_Post ID of the object. + * @param string $object_type The type of object. A lesson, section, course, or course_track. + * @param string $trigger String describing the reason for the status change. + * @return boolean + */ + private function update_favorite_status( $status, $object_id, $object_type, $trigger = 'unspecified' ) { + + $student_id = $this->get_id(); + + /** + * Fires before a student's object completion status is updated. + * + * The dynamic portion of this hook, `$status`, refers to the new completion status of the object, + * either "complete" or "incomplete" + * + * @since [version] + * + * @param int $student_id WP_User ID of the student. + * @param int $object_id WP_Post ID of the object. + * @param string $object_type The type of object. A lesson, section, course, or course_track. + * @param string $trigger String describing the reason for the status change. + */ + do_action( "before_llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); + + // Retrieve an instance of the object we're acting on. + if ( in_array( $object_type, llms_get_completable_post_types(), true ) ) { + $object = llms_get_post( $object_id ); + } elseif ( in_array( $object_type, llms_get_completable_taxonomies(), true ) ) { + $object = get_term( $object_id, $object_type ); + } else { + return false; + } + + // Insert meta data. + if ( 'favorite' === $status ) { + $this->insert_favorite_postmeta( $object_id, $trigger ); + } elseif ( 'unfavorite' === $status ) { + // TODO + $this->insert_unfavorite_postmeta( $object_id, $trigger ); + } + + /** + * Hook that fires when a student's completion status is updated for any object. + * + * The dynamic portion of this hook, `$status`, refers to the new favorite status of the object, + * either "favorite" or "unfavorite" + * + * @since [version] + * + * @param int $student_id WP_User ID of the student. + * @param int $object_id WP_Post ID of the object. + * @param string $object_type The type of object. A lesson, section, course, or course_track. + * @param string $trigger String describing the reason for the status change. + */ + do_action( "llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); + + /** + * Hook that fires when a student's favorite status is updated for a specific object type. + * + * The dynamic portion of this hook, `$object_type` refers to the WP_Post post_type of the object + * which the student's completion status is being updated for. + * + * The dynamic portion of this hook, `$status`, refers to the new completion status of the object, + * either "favorite" or "unfavorite" + * + * @since [version] + * + * @param int $student_id WP_User ID of the student. + * @param int $object_id WP_Post ID of the object. + */ + do_action( "lifterlms_{$object_type}_{$status}d", $student_id, $object_id ); + + return true; + + } + } diff --git a/templates/course/favorite.php b/templates/course/favorite.php new file mode 100644 index 0000000000..8bbfaeab8b --- /dev/null +++ b/templates/course/favorite.php @@ -0,0 +1,58 @@ +ID ); +$student = llms_get_student( get_current_user_id() ); +?> + +
+ + + + is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> + + + + + +
+ + + + + + + + + + 1, + 'classes' => 'auto button llms-favorite', + 'id' => 'llms_mark_favorite', + 'value' => apply_filters( 'lifterlms_mark_lesson_favorite_button_text', __( '', 'lifterlms' ), $lesson ), + 'last_column' => true, + 'name' => 'mark_favorite', + 'required' => false, + 'type' => 'submit', + ) + ); + ?> + + + +
+ + + + + +
From 77886e0b3936fa2e33f4908c3e71b9b560dbcdf0 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 13 Mar 2023 01:02:54 +0530 Subject: [PATCH 008/522] Fixed PHPCS errors --- .../class.llms.controller.favorites.php | 14 ++-- includes/functions/llms.functions.person.php | 6 +- includes/models/model.llms.student.php | 10 +-- templates/course/favorite.php | 64 +++++++++---------- 4 files changed, 47 insertions(+), 47 deletions(-) diff --git a/includes/controllers/class.llms.controller.favorites.php b/includes/controllers/class.llms.controller.favorites.php index 5ec7d4661f..37c7d516dd 100644 --- a/includes/controllers/class.llms.controller.favorites.php +++ b/includes/controllers/class.llms.controller.favorites.php @@ -81,8 +81,8 @@ private function get_object_id_from_form_data( $action ) { */ public function handle_favorite_form() { - $object_id = $this->get_object_id_from_form_data( 'favorite' ); - $object_type = llms_filter_input( INPUT_POST, 'type' ); + $object_id = $this->get_object_id_from_form_data( 'favorite' ); + $object_type = llms_filter_input( INPUT_POST, 'type' ); if ( is_null( $object_id ) ) { return; @@ -113,8 +113,8 @@ public function handle_favorite_form() { */ public function handle_unfavorite_form() { - $lesson_id = $this->get_object_id_from_form_data( 'unfavorite' ); - $object_type = llms_filter_input( INPUT_POST, 'type' ); + $lesson_id = $this->get_object_id_from_form_data( 'unfavorite' ); + $object_type = llms_filter_input( INPUT_POST, 'type' ); if ( is_null( $lesson_id ) ) { return; @@ -139,10 +139,10 @@ public function handle_unfavorite_form() { * * @since [version] * - * @param int $user_id User ID. - * @param int $object_id Object ID. + * @param int $user_id User ID. + * @param int $object_id Object ID. * @param string $object_type Object description string (Lesson, Course or Instructor). - * @param array $args Optional arguments. + * @param array $args Optional arguments. * @return void */ public function mark_favorite( $user_id, $object_id, $object_type = '', $args = array() ) { diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index e73f93b791..7ec1b968b3 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -342,9 +342,9 @@ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'uns * * @see LLMS_Student->mark_favorite() * - * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param int $object_type Object type [lesson|section|course|track]. + * @param int $user_id WP User ID. + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param int $object_type Object type [lesson|section|course|track]. * @return boolean */ function llms_mark_favorite( $user_id, $object_id, $object_type ) { diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index f18dfcca1c..771b945e6c 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1906,7 +1906,7 @@ public function is_favorite( $object_id, $object_type = 'course' ) { * @version [version] */ public function mark_favorite( $object_id, $object_type ) { - + // Short circuit if it's already favorited. if ( $this->is_favorite( $object_id, $object_type ) ) { return true; @@ -1934,7 +1934,7 @@ public function mark_favorite( $object_id, $object_type ) { * @return boolean */ private function update_favorite_status( $status, $object_id, $object_type, $trigger = 'unspecified' ) { - + $student_id = $this->get_id(); /** @@ -1951,7 +1951,7 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * @param string $trigger String describing the reason for the status change. */ do_action( "before_llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); - + // Retrieve an instance of the object we're acting on. if ( in_array( $object_type, llms_get_completable_post_types(), true ) ) { $object = llms_get_post( $object_id ); @@ -1960,7 +1960,7 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri } else { return false; } - + // Insert meta data. if ( 'favorite' === $status ) { $this->insert_favorite_postmeta( $object_id, $trigger ); @@ -1999,7 +1999,7 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * @param int $object_id WP_Post ID of the object. */ do_action( "lifterlms_{$object_type}_{$status}d", $student_id, $object_id ); - + return true; } diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 8bbfaeab8b..4c7c277df6 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -8,51 +8,51 @@ global $post; -$lesson = new LLMS_Lesson( $post->ID ); +$lesson = new LLMS_Lesson( $post->ID ); $student = llms_get_student( get_current_user_id() ); ?>
- - - is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> - - + + + is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> + + - + -
+ - + - - - - - + + + + + - 1, - 'classes' => 'auto button llms-favorite', - 'id' => 'llms_mark_favorite', - 'value' => apply_filters( 'lifterlms_mark_lesson_favorite_button_text', __( '', 'lifterlms' ), $lesson ), - 'last_column' => true, - 'name' => 'mark_favorite', - 'required' => false, - 'type' => 'submit', - ) - ); - ?> + 1, + 'classes' => 'auto button llms-favorite', + 'id' => 'llms_mark_favorite', + 'value' => apply_filters( 'lifterlms_mark_lesson_favorite_button_text', __( '', 'lifterlms' ), $lesson ), + 'last_column' => true, + 'name' => 'mark_favorite', + 'required' => false, + 'type' => 'submit', + ) + ); + ?> - + -
+ - + - +
From d8d1ff4b85bfda3f69e7a6b72223093aedb5d4b9 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 13 Mar 2023 14:01:55 +0530 Subject: [PATCH 009/522] Added Object (Lesson) Unfavorite functionality --- .../class.llms.controller.favorites.php | 4 +- includes/functions/llms.functions.person.php | 29 ++++++++--- includes/models/model.llms.student.php | 51 +++++++++++++++++-- templates/course/favorite.php | 29 ++++++++++- 4 files changed, 99 insertions(+), 14 deletions(-) diff --git a/includes/controllers/class.llms.controller.favorites.php b/includes/controllers/class.llms.controller.favorites.php index 37c7d516dd..2681fdddd5 100644 --- a/includes/controllers/class.llms.controller.favorites.php +++ b/includes/controllers/class.llms.controller.favorites.php @@ -113,10 +113,10 @@ public function handle_favorite_form() { */ public function handle_unfavorite_form() { - $lesson_id = $this->get_object_id_from_form_data( 'unfavorite' ); + $object_id = $this->get_object_id_from_form_data( 'unfavorite' ); $object_type = llms_filter_input( INPUT_POST, 'type' ); - if ( is_null( $lesson_id ) ) { + if ( is_null( $object_id ) ) { return; } diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index 7ec1b968b3..9bbe21a92f 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -335,6 +335,24 @@ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'uns return $student->mark_complete( $object_id, $object_type, $trigger ); } +/** + * Mark a lesson, section, course, or track as incomplete + * + * @since 3.5.0 + * + * @see LLMS_Student->mark_incomplete() + * + * @param int $user_id WP User ID. + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param int $object_type Object type [lesson|section|course|track]. + * @param string $trigger String describing the event that triggered marking the object as incomplete. + * @return boolean + */ +function llms_mark_incomplete( $user_id, $object_id, $object_type, $trigger = 'unspecified' ) { + $student = new LLMS_Student( $user_id ); + return $student->mark_incomplete( $object_id, $object_type, $trigger ); +} + /** * Mark an object as favorite * @@ -353,21 +371,20 @@ function llms_mark_favorite( $user_id, $object_id, $object_type ) { } /** - * Mark a lesson, section, course, or track as incomplete + * Mark a lesson as unfavorite * - * @since 3.5.0 + * @since [version] * - * @see LLMS_Student->mark_incomplete() + * @see LLMS_Student->mark_unfavorite() * * @param int $user_id WP User ID. * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. * @param int $object_type Object type [lesson|section|course|track]. - * @param string $trigger String describing the event that triggered marking the object as incomplete. * @return boolean */ -function llms_mark_incomplete( $user_id, $object_id, $object_type, $trigger = 'unspecified' ) { +function llms_mark_unfavorite( $user_id, $object_id, $object_type ) { $student = new LLMS_Student( $user_id ); - return $student->mark_incomplete( $object_id, $object_type, $trigger ); + return $student->mark_unfavorite( $object_id, $object_type ); } /** diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 771b945e6c..bdb5861c2b 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -27,6 +27,7 @@ * Added new filter to allow customization of object completion data. * @since 5.2.0 Changed the date to be relative to the local time zone in `get_registration_date`. * @since 6.0.0 Removed the deprecated `llms_user_removed_from_membership_level` action hook from the `LLMS_Student::unenroll()` method. + * @since [version] Added the logic to add and remove lesson favoritism. */ class LLMS_Student extends LLMS_Abstract_User_Data { @@ -1277,6 +1278,24 @@ private function insert_favorite_postmeta( $object_id, $trigger = 'unspecified' } + /** + * Remove student postmeta data when lesson is unfavorited + * + * @param int $object_id WP Post ID of the lesson + * @param string $trigger String describing the reason for mark completion + * @return boolean + * @since [version] + * @version [version] + */ + private function insert_unfavorite_postmeta( $object_id, $trigger = 'unspecified' ) { + + $update = llms_delete_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); + + // Returns an array with errored keys or true on success. + return is_array( $update ) ? false : true; + + } + /** * Add student postmeta data for enrollment into a course or membership * @@ -1893,11 +1912,10 @@ public function is_favorite( $object_id, $object_type = 'course' ) { } /** - * Mark a lesson, section, course, or track complete for the given user + * Mark a lesson, section, course, or track favorite for the given user * * @param int $object_id WP Post ID of the lesson, section, course, or track * @param string $object_type object type [lesson|section|course|track] - * @param string $trigger String describing the reason for marking complete * @return boolean * * @see llms_mark_favorite() calls this function without having to instantiate the LLMS_Student class first @@ -1916,6 +1934,29 @@ public function mark_favorite( $object_id, $object_type ) { } + /** + * Mark a lesson, section, course, or track unfavorite for the given user + * + * @param int $object_id WP Post ID of the lesson, section, course, or track + * @param string $object_type object type [lesson|section|course|track] + * @return boolean + * + * @see llms_mark_unfavorite() calls this function without having to instantiate the LLMS_Student class first + * + * @since [version] + * @version [version] + */ + public function mark_unfavorite( $object_id, $object_type ) { + + // Short circuit if it's not favorited. + if ( ! $this->is_favorite( $object_id, $object_type ) ) { + return true; + } + + return $this->update_favorite_status( 'unfavorite', $object_id, $object_type ); + + } + /** * Update the favorite status of a track, course, section, or lesson for the current student * @@ -1933,15 +1974,16 @@ public function mark_favorite( $object_id, $object_type ) { * @param string $trigger String describing the reason for the status change. * @return boolean */ + private function update_favorite_status( $status, $object_id, $object_type, $trigger = 'unspecified' ) { $student_id = $this->get_id(); /** - * Fires before a student's object completion status is updated. + * Fires before a student's object favorite status is updated. * * The dynamic portion of this hook, `$status`, refers to the new completion status of the object, - * either "complete" or "incomplete" + * either "favorite" or "unfavorite" * * @since [version] * @@ -1965,7 +2007,6 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri if ( 'favorite' === $status ) { $this->insert_favorite_postmeta( $object_id, $trigger ); } elseif ( 'unfavorite' === $status ) { - // TODO $this->insert_unfavorite_postmeta( $object_id, $trigger ); } diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 4c7c277df6..50eb167e84 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -18,7 +18,34 @@ is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> - +
+ + + + + + + + + + 12, + 'classes' => 'llms-button-secondary auto button', + 'id' => 'llms_mark_unfavorite', + 'value' => apply_filters( 'lifterlms_mark_lesson_unfavorite_button_text', __( '', 'lifterlms' ), $lesson ), + 'last_column' => true, + 'name' => 'mark_unfavorite', + 'required' => false, + 'type' => 'submit', + ) + ); + ?> + + + +
From fd8bab9202a4eea2a78a2411304175019ca57f5a Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 13 Mar 2023 17:07:55 +0530 Subject: [PATCH 010/522] Added favorite object (Lesson) count --- includes/functions/llms.functions.course.php | 31 +++++++++++++++++++- includes/models/model.llms.student.php | 2 +- templates/course/favorite.php | 4 +++ 3 files changed, 35 insertions(+), 2 deletions(-) diff --git a/includes/functions/llms.functions.course.php b/includes/functions/llms.functions.course.php index f987c74f24..c8136c5046 100644 --- a/includes/functions/llms.functions.course.php +++ b/includes/functions/llms.functions.course.php @@ -5,7 +5,7 @@ * @package LifterLMS/Functions * * @since Unknown - * @version 3.37.13 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -51,3 +51,32 @@ function get_lesson( $the_lesson = false, $args = array() ) { return new LLMS_Lesson( $the_lesson, $args ); } + +/** + * Get Favorites Count + * + * @since [version] + * + * @param WP_Post|int|false $object_id Lesson post object or id. If `false` uses the global `$post` object. + * @param array $args Arguments to pass to the LLMS_Lesson Constructor. + * @return Favorites Count + */ +function get_total_favorites( $object_id = false, $meta_key, $meta_value = '', $args = array() ) { + + global $wpdb; + + $key = $meta_key ? $wpdb->prepare( 'AND meta_key = %s', $meta_key ) : ''; + + // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared + $res = $wpdb->get_results( + $wpdb->prepare( + "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta + WHERE post_id = %d {$key} ORDER BY updated_date DESC", + $object_id + ) + ); + // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared + + return count( $res ); + +} diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index bdb5861c2b..847d2a6d2a 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1268,7 +1268,7 @@ private function insert_favorite_postmeta( $object_id, $trigger = 'unspecified' // Add info to the user postmeta table. $user_metadatas = array( '_is_favorite' => 'yes', - '_completion_trigger' => $trigger, + '_favorite_trigger' => $trigger, ); $update = llms_update_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 50eb167e84..047a5a1a6f 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -80,6 +80,10 @@ +
+ get( 'id' ), '_favorite' ); ?> +
+ From 45b98c2ff4f396ca04921720ed80d72fe2827b43 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 13 Mar 2023 19:06:59 +0530 Subject: [PATCH 011/522] PHPCS fixes --- includes/functions/llms.functions.course.php | 2 +- includes/functions/llms.functions.person.php | 9 ++++--- includes/models/model.llms.student.php | 25 ++++++++++---------- 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/includes/functions/llms.functions.course.php b/includes/functions/llms.functions.course.php index c8136c5046..e01766acf8 100644 --- a/includes/functions/llms.functions.course.php +++ b/includes/functions/llms.functions.course.php @@ -62,7 +62,7 @@ function get_lesson( $the_lesson = false, $args = array() ) { * @return Favorites Count */ function get_total_favorites( $object_id = false, $meta_key, $meta_value = '', $args = array() ) { - + global $wpdb; $key = $meta_key ? $wpdb->prepare( 'AND meta_key = %s', $meta_key ) : ''; diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index 9bbe21a92f..cfa62b54a1 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -330,7 +330,6 @@ function llms_is_user_enrolled( $user_id, $product_id, $relation = 'all', $use_c * @return boolean */ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'unspecified' ) { - // die('minus one'); $student = new LLMS_Student( $user_id ); return $student->mark_complete( $object_id, $object_type, $trigger ); } @@ -354,7 +353,7 @@ function llms_mark_incomplete( $user_id, $object_id, $object_type, $trigger = 'u } /** - * Mark an object as favorite + * Mark an object as favorite. * * @since [version] * @@ -377,9 +376,9 @@ function llms_mark_favorite( $user_id, $object_id, $object_type ) { * * @see LLMS_Student->mark_unfavorite() * - * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param int $object_type Object type [lesson|section|course|track]. + * @param int $user_id WP User ID. + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param int $object_type Object type [lesson|section|course|track]. * @return boolean */ function llms_mark_unfavorite( $user_id, $object_id, $object_type ) { diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 847d2a6d2a..e5ff280fa8 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1255,19 +1255,21 @@ private function insert_incompletion_postmeta( $object_id, $trigger = 'unspecifi } /** - * Add student postmeta data when lesson is favorited + * Add student postmeta data when lesson is favorited. * - * @param int $object_id WP Post ID of the lesson - * @param string $trigger String describing the reason for mark completion + * @since [version] + * + * @see LLMS_Student->mark_favorite() + * + * @param int $object_id WP User ID. + * @param int $trigger WP Post ID of the Lesson, Section, Track, or Course. * @return boolean - * @since [version] - * @version [version] */ private function insert_favorite_postmeta( $object_id, $trigger = 'unspecified' ) { // Add info to the user postmeta table. $user_metadatas = array( - '_is_favorite' => 'yes', + '_is_favorite' => 'yes', '_favorite_trigger' => $trigger, ); @@ -1279,10 +1281,10 @@ private function insert_favorite_postmeta( $object_id, $trigger = 'unspecified' } /** - * Remove student postmeta data when lesson is unfavorited + * Remove student postmeta data when lesson is unfavorited. * - * @param int $object_id WP Post ID of the lesson - * @param string $trigger String describing the reason for mark completion + * @param int $object_id WP Post ID of the lesson. + * @param string $trigger String describing the reason for mark completion. * @return boolean * @since [version] * @version [version] @@ -1887,8 +1889,8 @@ private function update_completion_status( $status, $object_id, $object_type, $t /** * Determine if the student has favorited a lesson * - * @param int $object_id WP Post ID of a course or lesson or section or the term id of the track - * @param string $type Object type (course, lesson, section, or track) + * @param int $object_id WP Post ID of a course or lesson or section or the term id of the track + * @param string $object_type Object type (course, lesson, section, or track) * @return boolean * @since [version] * @version [version] @@ -1974,7 +1976,6 @@ public function mark_unfavorite( $object_id, $object_type ) { * @param string $trigger String describing the reason for the status change. * @return boolean */ - private function update_favorite_status( $status, $object_id, $object_type, $trigger = 'unspecified' ) { $student_id = $this->get_id(); From f9663e5b58215b83cc2b0121d81951f882af6a71 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Tue, 14 Mar 2023 14:40:21 +0530 Subject: [PATCH 012/522] Doc Blocks and PHPCS fixes --- .../class.llms.controller.favorites.php | 17 ++++-- ...ass.llms.controller.lesson.progression.php | 2 +- includes/functions/llms.functions.course.php | 5 +- includes/llms.template.functions.php | 4 +- includes/models/model.llms.student.php | 55 +++++++++++-------- templates/course/favorite.php | 13 ++++- 6 files changed, 61 insertions(+), 35 deletions(-) diff --git a/includes/controllers/class.llms.controller.favorites.php b/includes/controllers/class.llms.controller.favorites.php index 2681fdddd5..d81cecb254 100644 --- a/includes/controllers/class.llms.controller.favorites.php +++ b/includes/controllers/class.llms.controller.favorites.php @@ -91,12 +91,21 @@ public function handle_favorite_form() { /** * Filter to modify the user id instead of current logged in user id. * - * @param int $user_id User id to mark lesson as favorite. - * * @since [version] + * + * @param int $user_id User id to mark lesson as favorite. */ $user_id = apply_filters( 'llms_object_favorite_user_id', get_current_user_id() ); + /** + * Action triggered for saving the favorite object to it's own postmeta. + * + * @since [version] + * + * @param int $user_id User ID who is marking object as favorite. + * @param int $object_id Object ID (Lesson, Course or Instructor). + * @param string $object_type Object description string (Lesson, Course or Instructor). + */ do_action( 'llms_trigger_object_favorite', $user_id, $object_id, $object_type ); } @@ -123,9 +132,9 @@ public function handle_unfavorite_form() { /** * Filter to modify the user id instead of current logged in user id. * - * @param int $user_id User id to mark object as unfavorite. - * * @since [version] + * + * @param int $user_id User id to mark lesson as favorite. */ $user_id = apply_filters( 'llms_object_unfavorite_user_id', get_current_user_id() ); diff --git a/includes/controllers/class.llms.controller.lesson.progression.php b/includes/controllers/class.llms.controller.lesson.progression.php index de703a995f..c138644720 100644 --- a/includes/controllers/class.llms.controller.lesson.progression.php +++ b/includes/controllers/class.llms.controller.lesson.progression.php @@ -44,7 +44,7 @@ public function __construct() { * * @since 3.29.0 * - * @param String $action Form action, either "complete" or "incomplete". + * @param string $action Form action, either "complete" or "incomplete". * @return int|null Returns `null` when either required post fields are missing or if the lesson_id is non-numeric, int (lesson id) on success. */ private function get_lesson_id_from_form_data( $action ) { diff --git a/includes/functions/llms.functions.course.php b/includes/functions/llms.functions.course.php index e01766acf8..c4b86e9387 100644 --- a/includes/functions/llms.functions.course.php +++ b/includes/functions/llms.functions.course.php @@ -57,11 +57,12 @@ function get_lesson( $the_lesson = false, $args = array() ) { * * @since [version] * - * @param WP_Post|int|false $object_id Lesson post object or id. If `false` uses the global `$post` object. + * @param WP_Post|int|false $object_id Lesson post object or id. If `false` uses the global `$post` object. + * @param string $meta_key Optional meta key to use in the WHERE condition. * @param array $args Arguments to pass to the LLMS_Lesson Constructor. * @return Favorites Count */ -function get_total_favorites( $object_id = false, $meta_key, $meta_value = '', $args = array() ) { +function get_total_favorites( $object_id = false, $meta_key, $args = array() ) { global $wpdb; diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index c663b1d87c..618ba013ea 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -386,7 +386,9 @@ function lifterlms_template_single_parent_course() { } /** - * Favorite Lesson Template Include + * Favorite Lesson Template Include. + * + * @since [version] * * @return void */ diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index e5ff280fa8..04fa07d1fa 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1283,13 +1283,13 @@ private function insert_favorite_postmeta( $object_id, $trigger = 'unspecified' /** * Remove student postmeta data when lesson is unfavorited. * + * @since [version] + * * @param int $object_id WP Post ID of the lesson. * @param string $trigger String describing the reason for mark completion. * @return boolean - * @since [version] - * @version [version] */ - private function insert_unfavorite_postmeta( $object_id, $trigger = 'unspecified' ) { + private function remove_unfavorite_postmeta( $object_id, $trigger = 'unspecified' ) { $update = llms_delete_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); @@ -1889,11 +1889,11 @@ private function update_completion_status( $status, $object_id, $object_type, $t /** * Determine if the student has favorited a lesson * + * @since [version] + * * @param int $object_id WP Post ID of a course or lesson or section or the term id of the track * @param string $object_type Object type (course, lesson, section, or track) * @return boolean - * @since [version] - * @version [version] */ public function is_favorite( $object_id, $object_type = 'course' ) { @@ -1909,6 +1909,18 @@ public function is_favorite( $object_id, $object_type = 'course' ) { $ret = $query->has_results(); + /** + * Filter object favorite boolean value prior to returning + * + * The dynamic portion of this filter, `{$object_type}`, refers to the Lesson, Course or Instructor. + * + * @since [version] + * + * @param array|false $ret Array of favorite data or `false` if no favorite is found. + * @param int $object_id Object ID (Lesson, Course or Instructor). + * @param string $object_type Object description string (Lesson, Course or Instructor). + * @param LLMS_Student $instance The Student Instance + */ return apply_filters( 'llms_is_' . $object_type . '_favorite', $ret, $object_id, $object_type, $this ); } @@ -1916,14 +1928,13 @@ public function is_favorite( $object_id, $object_type = 'course' ) { /** * Mark a lesson, section, course, or track favorite for the given user * + * @since [version] + * + * @see llms_mark_favorite() calls this function without having to instantiate the LLMS_Student class first + * * @param int $object_id WP Post ID of the lesson, section, course, or track * @param string $object_type object type [lesson|section|course|track] * @return boolean - * - * @see llms_mark_favorite() calls this function without having to instantiate the LLMS_Student class first - * - * @since [version] - * @version [version] */ public function mark_favorite( $object_id, $object_type ) { @@ -1939,14 +1950,13 @@ public function mark_favorite( $object_id, $object_type ) { /** * Mark a lesson, section, course, or track unfavorite for the given user * - * @param int $object_id WP Post ID of the lesson, section, course, or track - * @param string $object_type object type [lesson|section|course|track] - * @return boolean + * @since [version] * * @see llms_mark_unfavorite() calls this function without having to instantiate the LLMS_Student class first * - * @since [version] - * @version [version] + * @param int $object_id WP Post ID of the lesson, section, course, or track + * @param string $object_type object type [lesson|section|course|track] + * @return boolean */ public function mark_unfavorite( $object_id, $object_type ) { @@ -1960,17 +1970,14 @@ public function mark_unfavorite( $object_id, $object_type ) { } /** - * Update the favorite status of a track, course, section, or lesson for the current student - * * Triggers actions for favorite/unfavorite. * + * Update the favorite status of a track, course, section, or lesson for the current student * Inserts / updates necessary user postmeta data. * - * @since [version] - * @since 4.2.0 Use filterable functions to determine if the object is completable. - * Added filter to allow customization of object parent data. + * @since [version] Use filterable functions to determine if the object can be marked favorite. * - * @param string $status New status to update to, either "complete" or "incomplete". + * @param string $status New status to update to, either "favorite" or "unfavorite". * @param int $object_id WP_Post ID of the object. * @param string $object_type The type of object. A lesson, section, course, or course_track. * @param string $trigger String describing the reason for the status change. @@ -2004,15 +2011,15 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri return false; } - // Insert meta data. + // Insert / Remove meta data. if ( 'favorite' === $status ) { $this->insert_favorite_postmeta( $object_id, $trigger ); } elseif ( 'unfavorite' === $status ) { - $this->insert_unfavorite_postmeta( $object_id, $trigger ); + $this->remove_unfavorite_postmeta( $object_id, $trigger ); } /** - * Hook that fires when a student's completion status is updated for any object. + * Hook that fires when a student's favorite status is updated for any object. * * The dynamic portion of this hook, `$status`, refers to the new favorite status of the object, * either "favorite" or "unfavorite" diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 047a5a1a6f..368c776f2b 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -1,9 +1,16 @@ Date: Tue, 14 Mar 2023 15:01:59 +0530 Subject: [PATCH 013/522] Fixed PHPCS tabs errors --- includes/models/model.llms.student.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 04fa07d1fa..d6c5f8dfca 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1916,10 +1916,10 @@ public function is_favorite( $object_id, $object_type = 'course' ) { * * @since [version] * - * @param array|false $ret Array of favorite data or `false` if no favorite is found. - * @param int $object_id Object ID (Lesson, Course or Instructor). - * @param string $object_type Object description string (Lesson, Course or Instructor). - * @param LLMS_Student $instance The Student Instance + * @param array|false $ret Array of favorite data or `false` if no favorite is found. + * @param int $object_id Object ID (Lesson, Course or Instructor). + * @param string $object_type Object description string (Lesson, Course or Instructor). + * @param LLMS_Student $instance The Student Instance */ return apply_filters( 'llms_is_' . $object_type . '_favorite', $ret, $object_id, $object_type, $this ); From 761452165d418e4cde23a39924f814fc031c02fc Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 16 Mar 2023 16:53:28 +0530 Subject: [PATCH 014/522] Added AJAX handler for favorite/unfavorite --- assets/js/llms-favorites.js | 80 +++++++++++++++++++++++++ includes/assets/llms-assets-scripts.php | 4 ++ includes/class.llms.ajax.php | 43 +++++++++++++ includes/class.llms.frontend.assets.php | 5 ++ templates/course/favorite.php | 23 +++---- 5 files changed, 145 insertions(+), 10 deletions(-) create mode 100644 assets/js/llms-favorites.js diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js new file mode 100644 index 0000000000..98ec13e8b7 --- /dev/null +++ b/assets/js/llms-favorites.js @@ -0,0 +1,80 @@ +;/* global LLMS, $ */ +/* jshint strict: true */ + +/** + * Front End Favorite Class + * + * @type {Object} + * @since [version] + * @version [version] + */ +( function( $ ) { + + var favorite = { + + /** + * Bind DOM events + * + * @return void + * @since [version] + * @version [version] + */ + bind: function() { + + var self = this; + + // Favorite clicked + $( '.llms-favorite-wrapper .llms-favorite-action' ).on( 'click', function( e ) { + e.preventDefault(); + self.favorite( $( this ) ); + } ); + + }, + + /** + * Favorite / Unfavorite an object + * + * @param obj $btn jQuery object for the "Favorite / Unfavorite" button + * @return void + * @since [version] + * @version [version] + */ + favorite: function( $btn ) { + + var self = this, + object_id = $btn.attr( 'data-id' ), + object_type = $btn.attr( 'data-type' ) + user_action = $btn.attr( 'data-action' ); + + console.log( 'before ajax', object_id, object_type, user_action ); + + LLMS.Ajax.call( { + data: { + action: 'favorite_object', + object_id: object_id, + object_type: object_type, + user_action: user_action + }, + beforeSend: function() { + + console.log('before send'); + + }, + success: function( r ) { + + console.log('result', r ); + + } + + } ); + + } + + }; + + favorite.bind(); + + window.llms = window.llms || {}; + window.llms.favorites = favorite; + +} )( jQuery ); diff --git a/includes/assets/llms-assets-scripts.php b/includes/assets/llms-assets-scripts.php index c8bf2773d8..434485c026 100644 --- a/includes/assets/llms-assets-scripts.php +++ b/includes/assets/llms-assets-scripts.php @@ -33,6 +33,7 @@ * @since 6.0.0 Added llms-admin-certificate-editor. * @since 6.10.0 Added llms-quill-wordcount. * @since 7.0.0 Added llms-spinner. + * @since [version] Added llms-favorites. */ return array( @@ -49,6 +50,9 @@ 'llms-quiz' => array( 'dependencies' => array( 'jquery', 'llms', 'wp-mediaelement' ), ), + 'llms-favorites' => array( + 'dependencies' => array( 'jquery', 'llms' ), + ), // Admin. 'llms-addons' => array( diff --git a/includes/class.llms.ajax.php b/includes/class.llms.ajax.php index 1a3bdde781..49000ebb4e 100644 --- a/includes/class.llms.ajax.php +++ b/includes/class.llms.ajax.php @@ -38,6 +38,7 @@ class LLMS_AJAX { * @since 4.0.0 Stop registering previously deprecated actions. * @since 5.9.0 Move `check_voucher_duplicate()` to `LLMS_AJAX_Handler`. * @since 6.0.0 Removed loading of class files that don't instantiate their class in favor of autoloading. + * @since [version] Added `favorite_object` ajax event. * * @return void */ @@ -45,6 +46,7 @@ public function __construct() { $ajax_events = array( 'query_quiz_questions' => false, + 'favorite_object' => false, ); foreach ( $ajax_events as $ajax_event => $nopriv ) { @@ -207,6 +209,47 @@ public function query_quiz_questions() { } + /** + * Add Favorite / Unfavorite Postmeta for an object. + * + * @since [version] + * + * @return void + */ + public function favorite_object() { + + // Grab the data if it exists. + $user_action = array_key_exists( 'user_action', $_REQUEST ) ? llms_filter_input_sanitize_string( INPUT_POST, 'user_action' ) : ''; + $object_id = array_key_exists( 'object_id', $_REQUEST ) ? llms_filter_input( INPUT_POST, 'object_id', FILTER_SANITIZE_NUMBER_INT ) : 0; + $object_type = array_key_exists( 'object_type', $_REQUEST ) ? llms_filter_input_sanitize_string( INPUT_POST, 'object_type' ) : ''; + + if ( is_null( $object_id ) ) { + return; + } + + /** + * Filter to modify the user id instead of current logged in user id. + * + * @since [version] + * + * @param int $user_id User id to mark lesson as favorite. + */ + $user_id = apply_filters( 'llms_object_favorite_user_id', get_current_user_id() ); + + if ( 'favorite' === $user_action ) { + + $r = llms_mark_favorite( $user_id, $object_id, $object_type ); + + } elseif ( 'unfavorite' === $user_action ) { + + $r = llms_mark_unfavorite( $user_id, $object_id, $object_type ); + + } + + wp_die(); + + } + } new LLMS_AJAX(); diff --git a/includes/class.llms.frontend.assets.php b/includes/class.llms.frontend.assets.php index a8eed0a3ab..9635eac0dd 100644 --- a/includes/class.llms.frontend.assets.php +++ b/includes/class.llms.frontend.assets.php @@ -166,6 +166,7 @@ public static function enqueue_styles() { * Moved inline scripts to `enqueue_inline_scripts()`. * @since 5.0.0 Enqueue locale data and dependencies on account and checkout pages for searchable dropdowns for country & state. * Remove password strength inline enqueue. + * @since [version] Enqueue `llms-favorites` script. * * @return void */ @@ -200,6 +201,10 @@ public static function enqueue_scripts() { llms()->assets->enqueue_script( 'llms-quiz' ); } + if ( is_lesson() ) { // TODO: check if favorites is enabled and enqueue script on right places + llms()->assets->enqueue_script( 'llms-favorites' ); + } + llms()->assets->register_script( 'llms-iziModal' ); if ( is_llms_account_page() ) { llms()->assets->enqueue_script( 'llms-iziModal' ); diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 368c776f2b..c4bdc75814 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -17,6 +17,7 @@ $lesson = new LLMS_Lesson( $post->ID ); $student = llms_get_student( get_current_user_id() ); +$total_favorites = get_total_favorites( $lesson->get( 'id' ) ); ?>
@@ -24,7 +25,10 @@ is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> - + + + +
@@ -39,9 +43,9 @@ llms_form_field( array( 'columns' => 12, - 'classes' => 'llms-button-secondary auto button', + 'classes' => 'llms-button-secondary', 'id' => 'llms_mark_unfavorite', - 'value' => apply_filters( 'lifterlms_mark_lesson_unfavorite_button_text', __( '', 'lifterlms' ), $lesson ), + 'value' => apply_filters( 'lifterlms_mark_lesson_unfavorite_button_text', sprintf( ' %d', $total_favorites ), $lesson ), 'last_column' => true, 'name' => 'mark_unfavorite', 'required' => false, @@ -55,6 +59,9 @@
+ + +
@@ -69,10 +76,10 @@ 1, - 'classes' => 'auto button llms-favorite', + 'columns' => 12, + 'classes' => 'llms-button-primary button llms-favorite', 'id' => 'llms_mark_favorite', - 'value' => apply_filters( 'lifterlms_mark_lesson_favorite_button_text', __( '', 'lifterlms' ), $lesson ), + 'value' => apply_filters( 'lifterlms_mark_lesson_favorite_button_text', sprintf( ' %d', $total_favorites ), $lesson ), 'last_column' => true, 'name' => 'mark_favorite', 'required' => false, @@ -87,10 +94,6 @@ -
- get( 'id' ), '_favorite' ); ?> -
-
From 8ea82eccf0ae71eecfb3ed1b5e447aaf31e219c2 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 16 Mar 2023 16:57:48 +0530 Subject: [PATCH 015/522] =?UTF-8?q?Minor=20fixes,=20form=20handler=20repla?= =?UTF-8?q?ced=20with=20AJAX=20=F0=9F=92=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- includes/class-llms-loader.php | 1 - .../class.llms.controller.favorites.php | 169 ------------------ includes/functions/llms.functions.course.php | 10 +- 3 files changed, 4 insertions(+), 176 deletions(-) delete mode 100644 includes/controllers/class.llms.controller.favorites.php diff --git a/includes/class-llms-loader.php b/includes/class-llms-loader.php index e8d79430d0..a952d0ce3e 100644 --- a/includes/class-llms-loader.php +++ b/includes/class-llms-loader.php @@ -286,7 +286,6 @@ public function includes() { require_once LLMS_PLUGIN_DIR . 'includes/controllers/class-llms-controller-awards.php'; require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.certificates.php'; require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.lesson.progression.php'; - require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.favorites.php'; require_once LLMS_PLUGIN_DIR . 'includes/controllers/class-llms-controller-checkout.php'; // Added out of alpha order to preserve action load order. require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.orders.php'; require_once LLMS_PLUGIN_DIR . 'includes/controllers/class.llms.controller.quizzes.php'; diff --git a/includes/controllers/class.llms.controller.favorites.php b/includes/controllers/class.llms.controller.favorites.php deleted file mode 100644 index d81cecb254..0000000000 --- a/includes/controllers/class.llms.controller.favorites.php +++ /dev/null @@ -1,169 +0,0 @@ -get_object_id_from_form_data( 'favorite' ); - $object_type = llms_filter_input( INPUT_POST, 'type' ); - - if ( is_null( $object_id ) ) { - return; - } - - /** - * Filter to modify the user id instead of current logged in user id. - * - * @since [version] - * - * @param int $user_id User id to mark lesson as favorite. - */ - $user_id = apply_filters( 'llms_object_favorite_user_id', get_current_user_id() ); - - /** - * Action triggered for saving the favorite object to it's own postmeta. - * - * @since [version] - * - * @param int $user_id User ID who is marking object as favorite. - * @param int $object_id Object ID (Lesson, Course or Instructor). - * @param string $object_type Object description string (Lesson, Course or Instructor). - */ - do_action( 'llms_trigger_object_favorite', $user_id, $object_id, $object_type ); - - } - - /** - * Mark Object as unfavorite - * - * + Unfavorite Object form post. - * + Marks Object as Unfavorite. - * - * @since [version] - * - * @return void - */ - public function handle_unfavorite_form() { - - $object_id = $this->get_object_id_from_form_data( 'unfavorite' ); - $object_type = llms_filter_input( INPUT_POST, 'type' ); - - if ( is_null( $object_id ) ) { - return; - } - - /** - * Filter to modify the user id instead of current logged in user id. - * - * @since [version] - * - * @param int $user_id User id to mark lesson as favorite. - */ - $user_id = apply_filters( 'llms_object_unfavorite_user_id', get_current_user_id() ); - - // Mark unfavorite. - llms_mark_unfavorite( $user_id, $object_id, $object_type ); - - } - - /** - * Handle favoriting of object via `llms_trigger_object_favorite` action - * - * @since [version] - * - * @param int $user_id User ID. - * @param int $object_id Object ID. - * @param string $object_type Object description string (Lesson, Course or Instructor). - * @param array $args Optional arguments. - * @return void - */ - public function mark_favorite( $user_id, $object_id, $object_type = '', $args = array() ) { - - if ( llms_allow_lesson_completion( $user_id, $object_id, $object_type, $args ) ) { - - llms_mark_favorite( $user_id, $object_id, $object_type ); - - } - - } - -} - -return new LLMS_Controller_Favorite(); diff --git a/includes/functions/llms.functions.course.php b/includes/functions/llms.functions.course.php index c4b86e9387..087e722a13 100644 --- a/includes/functions/llms.functions.course.php +++ b/includes/functions/llms.functions.course.php @@ -58,22 +58,20 @@ function get_lesson( $the_lesson = false, $args = array() ) { * @since [version] * * @param WP_Post|int|false $object_id Lesson post object or id. If `false` uses the global `$post` object. - * @param string $meta_key Optional meta key to use in the WHERE condition. * @param array $args Arguments to pass to the LLMS_Lesson Constructor. * @return Favorites Count */ -function get_total_favorites( $object_id = false, $meta_key, $args = array() ) { +function get_total_favorites( $object_id = false, $args = array() ) { global $wpdb; - $key = $meta_key ? $wpdb->prepare( 'AND meta_key = %s', $meta_key ) : ''; - // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared $res = $wpdb->get_results( $wpdb->prepare( "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta - WHERE post_id = %d {$key} ORDER BY updated_date DESC", - $object_id + WHERE post_id = %d AND meta_key = %s ORDER BY updated_date DESC", + $object_id, + '_favorite' ) ); // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared From e38a0050274de4543292f774f3d0cc451558ff4a Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 16 Mar 2023 17:32:28 +0530 Subject: [PATCH 016/522] Added AJAX function to update data --- assets/js/llms-favorites.js | 41 ++++++++++++++----- templates/course/favorite.php | 74 +++++------------------------------ 2 files changed, 41 insertions(+), 74 deletions(-) diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index 98ec13e8b7..4119b89b5e 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -12,6 +12,13 @@ var favorite = { + /** + * Main Favorite Container Element + * + * @type obj + */ + $container: null, + /** * Bind DOM events * @@ -24,7 +31,7 @@ var self = this; // Favorite clicked - $( '.llms-favorite-wrapper .llms-favorite-action' ).on( 'click', function( e ) { + $( '.llms-favorite-wrapper' ).on( 'click', '.llms-heart-btn', function( e ) { e.preventDefault(); self.favorite( $( this ) ); } ); @@ -41,13 +48,13 @@ */ favorite: function( $btn ) { - var self = this, + this.$container = $btn.closest( '.llms-favorite-wrapper' ); + + var self = this, object_id = $btn.attr( 'data-id' ), - object_type = $btn.attr( 'data-type' ) + object_type = $btn.attr( 'data-type' ), user_action = $btn.attr( 'data-action' ); - console.log( 'before ajax', object_id, object_type, user_action ); - LLMS.Ajax.call( { data: { action: 'favorite_object', @@ -55,14 +62,28 @@ object_type: object_type, user_action: user_action }, - beforeSend: function() { + beforeSend: function() {}, + success: function( r ) { + + if( r.success ) { - console.log('before send'); + if( 'favorite' === user_action ) { - }, - success: function( r ) { + $btn.removeClass( 'fa-heart-o' ).addClass( 'fa-heart' ); + $( $btn ).attr( 'data-action', 'unfavorite' ); + + } else if ( 'unfavorite' === user_action ) { + + $btn.removeClass( 'fa-heart' ).addClass( 'fa-heart-o' ); + $( $btn ).attr( 'data-action', 'favorite' ); + + } + + // Updating count. + self.$container.find( '.llms-favorites-count' ).text( r.total_favorites ); + - console.log('result', r ); + } } diff --git a/templates/course/favorite.php b/templates/course/favorite.php index c4bdc75814..7d56563424 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -15,8 +15,8 @@ global $post; -$lesson = new LLMS_Lesson( $post->ID ); -$student = llms_get_student( get_current_user_id() ); +$lesson = new LLMS_Lesson( $post->ID ); +$student = llms_get_student( get_current_user_id() ); $total_favorites = get_total_favorites( $lesson->get( 'id' ) ); ?> @@ -26,74 +26,20 @@ is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> - - - - - - - - - - - - - - 12, - 'classes' => 'llms-button-secondary', - 'id' => 'llms_mark_unfavorite', - 'value' => apply_filters( 'lifterlms_mark_lesson_unfavorite_button_text', sprintf( ' %d', $total_favorites ), $lesson ), - 'last_column' => true, - 'name' => 'mark_unfavorite', - 'required' => false, - 'type' => 'submit', - ) - ); - ?> - - - - + + - - - -
- - - - - - - - - - 12, - 'classes' => 'llms-button-primary button llms-favorite', - 'id' => 'llms_mark_favorite', - 'value' => apply_filters( 'lifterlms_mark_lesson_favorite_button_text', sprintf( ' %d', $total_favorites ), $lesson ), - 'last_column' => true, - 'name' => 'mark_favorite', - 'required' => false, - 'type' => 'submit', - ) - ); - ?> - - - -
+ + + + + + From 771adbe963ed10a6e1500d871491d968c1a696ff Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Fri, 17 Mar 2023 00:58:55 +0530 Subject: [PATCH 017/522] =?UTF-8?q?Minor=20fixes=20=F0=9F=9B=A0=EF=B8=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/js/llms-favorites.js | 10 ++--- includes/class-llms-loader.php | 1 - includes/class.llms.ajax.php | 23 +++++----- includes/class.llms.frontend.assets.php | 2 +- includes/functions/llms.functions.course.php | 7 ++-- includes/functions/llms.functions.person.php | 2 +- includes/models/model.llms.student.php | 44 ++++++++------------ templates/course/favorite.php | 2 +- 8 files changed, 40 insertions(+), 51 deletions(-) diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index 4119b89b5e..bc29a013aa 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -2,7 +2,7 @@ /* jshint strict: true */ /** - * Front End Favorite Class + * Front End Favorite Class. * * @type {Object} * @since [version] @@ -13,14 +13,14 @@ var favorite = { /** - * Main Favorite Container Element + * Main Favorite Container Element. * * @type obj */ $container: null, /** - * Bind DOM events + * Bind DOM events. * * @return void * @since [version] @@ -39,9 +39,9 @@ }, /** - * Favorite / Unfavorite an object + * Favorite / Unfavorite an object. * - * @param obj $btn jQuery object for the "Favorite / Unfavorite" button + * @param obj $btn jQuery object for the "Favorite / Unfavorite" button. * @return void * @since [version] * @version [version] diff --git a/includes/class-llms-loader.php b/includes/class-llms-loader.php index a952d0ce3e..eae5d74761 100644 --- a/includes/class-llms-loader.php +++ b/includes/class-llms-loader.php @@ -232,7 +232,6 @@ public function autoload( $class ) { * Removed loading of class files that don't instantiate their class in favor of autoloading. * @since 6.4.0 Included `LLMS_Shortcodes` before `LLMS_Controller_Orders`. * @since 7.0.0 Include `LLMS_Controller_Checkout`. - * @since [version] Include `LLMS_Controller_Favorite`. * * @return void */ diff --git a/includes/class.llms.ajax.php b/includes/class.llms.ajax.php index 49000ebb4e..96bb3bd45c 100644 --- a/includes/class.llms.ajax.php +++ b/includes/class.llms.ajax.php @@ -219,23 +219,15 @@ public function query_quiz_questions() { public function favorite_object() { // Grab the data if it exists. - $user_action = array_key_exists( 'user_action', $_REQUEST ) ? llms_filter_input_sanitize_string( INPUT_POST, 'user_action' ) : ''; - $object_id = array_key_exists( 'object_id', $_REQUEST ) ? llms_filter_input( INPUT_POST, 'object_id', FILTER_SANITIZE_NUMBER_INT ) : 0; - $object_type = array_key_exists( 'object_type', $_REQUEST ) ? llms_filter_input_sanitize_string( INPUT_POST, 'object_type' ) : ''; + $user_action = llms_filter_input_sanitize_string( INPUT_POST, 'user_action' ); + $object_id = llms_filter_input( INPUT_POST, 'object_id', FILTER_SANITIZE_NUMBER_INT ); + $object_type = llms_filter_input_sanitize_string( INPUT_POST, 'object_type' ); + $user_id = get_current_user_id(); if ( is_null( $object_id ) ) { return; } - /** - * Filter to modify the user id instead of current logged in user id. - * - * @since [version] - * - * @param int $user_id User id to mark lesson as favorite. - */ - $user_id = apply_filters( 'llms_object_favorite_user_id', get_current_user_id() ); - if ( 'favorite' === $user_action ) { $r = llms_mark_favorite( $user_id, $object_id, $object_type ); @@ -246,6 +238,13 @@ public function favorite_object() { } + echo json_encode( + array( + 'total_favorites' => get_total_favorites( $object_id ), + 'success' => true, + ) + ); + wp_die(); } diff --git a/includes/class.llms.frontend.assets.php b/includes/class.llms.frontend.assets.php index 9635eac0dd..be9f2761e3 100644 --- a/includes/class.llms.frontend.assets.php +++ b/includes/class.llms.frontend.assets.php @@ -201,7 +201,7 @@ public static function enqueue_scripts() { llms()->assets->enqueue_script( 'llms-quiz' ); } - if ( is_lesson() ) { // TODO: check if favorites is enabled and enqueue script on right places + if ( is_lesson() ) { // TODO: check if favorites is enabled and enqueue script on right places. llms()->assets->enqueue_script( 'llms-favorites' ); } diff --git a/includes/functions/llms.functions.course.php b/includes/functions/llms.functions.course.php index 087e722a13..7484d50fca 100644 --- a/includes/functions/llms.functions.course.php +++ b/includes/functions/llms.functions.course.php @@ -53,15 +53,14 @@ function get_lesson( $the_lesson = false, $args = array() ) { } /** - * Get Favorites Count + * Get Favorites Count. * * @since [version] * * @param WP_Post|int|false $object_id Lesson post object or id. If `false` uses the global `$post` object. - * @param array $args Arguments to pass to the LLMS_Lesson Constructor. - * @return Favorites Count + * @return int */ -function get_total_favorites( $object_id = false, $args = array() ) { +function get_total_favorites( $object_id = false ) { global $wpdb; diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index cfa62b54a1..b06313e17b 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -370,7 +370,7 @@ function llms_mark_favorite( $user_id, $object_id, $object_type ) { } /** - * Mark a lesson as unfavorite + * Mark a lesson as unfavorite. * * @since [version] * diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index d6c5f8dfca..bf9a3d2c8e 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1262,16 +1262,9 @@ private function insert_incompletion_postmeta( $object_id, $trigger = 'unspecifi * @see LLMS_Student->mark_favorite() * * @param int $object_id WP User ID. - * @param int $trigger WP Post ID of the Lesson, Section, Track, or Course. * @return boolean */ - private function insert_favorite_postmeta( $object_id, $trigger = 'unspecified' ) { - - // Add info to the user postmeta table. - $user_metadatas = array( - '_is_favorite' => 'yes', - '_favorite_trigger' => $trigger, - ); + private function insert_favorite_postmeta( $object_id ) { $update = llms_update_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); @@ -1285,11 +1278,10 @@ private function insert_favorite_postmeta( $object_id, $trigger = 'unspecified' * * @since [version] * - * @param int $object_id WP Post ID of the lesson. - * @param string $trigger String describing the reason for mark completion. + * @param int $object_id WP Post ID of the lesson * @return boolean */ - private function remove_unfavorite_postmeta( $object_id, $trigger = 'unspecified' ) { + private function remove_unfavorite_postmeta( $object_id ) { $update = llms_delete_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); @@ -1887,15 +1879,15 @@ private function update_completion_status( $status, $object_id, $object_type, $t } /** - * Determine if the student has favorited a lesson + * Determine if the student has favorited a lesson. * * @since [version] * - * @param int $object_id WP Post ID of a course or lesson or section or the term id of the track - * @param string $object_type Object type (course, lesson, section, or track) + * @param int $object_id WP Post ID of a course or lesson or section or the term id of the track. + * @param string $object_type Object type (course, lesson, section, or track). * @return boolean */ - public function is_favorite( $object_id, $object_type = 'course' ) { + public function is_favorite( $object_id, $object_type = 'lesson' ) { $query = new LLMS_Query_User_Postmeta( array( @@ -1926,14 +1918,14 @@ public function is_favorite( $object_id, $object_type = 'course' ) { } /** - * Mark a lesson, section, course, or track favorite for the given user + * Mark a lesson, section, course, or track favorite for the given user. * * @since [version] * - * @see llms_mark_favorite() calls this function without having to instantiate the LLMS_Student class first + * @see llms_mark_favorite() calls this function without having to instantiate the LLMS_Student class first. * - * @param int $object_id WP Post ID of the lesson, section, course, or track - * @param string $object_type object type [lesson|section|course|track] + * @param int $object_id WP Post ID of the lesson, section, course, or track. + * @param string $object_type object type [lesson|section|course|track]. * @return boolean */ public function mark_favorite( $object_id, $object_type ) { @@ -1948,14 +1940,14 @@ public function mark_favorite( $object_id, $object_type ) { } /** - * Mark a lesson, section, course, or track unfavorite for the given user + * Mark a lesson, section, course, or track unfavorite for the given user. * * @since [version] * - * @see llms_mark_unfavorite() calls this function without having to instantiate the LLMS_Student class first + * @see llms_mark_unfavorite() calls this function without having to instantiate the LLMS_Student class first. * - * @param int $object_id WP Post ID of the lesson, section, course, or track - * @param string $object_type object type [lesson|section|course|track] + * @param int $object_id WP Post ID of the lesson, section, course, or track. + * @param string $object_type object type [lesson|section|course|track]. * @return boolean */ public function mark_unfavorite( $object_id, $object_type ) { @@ -1991,7 +1983,7 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * Fires before a student's object favorite status is updated. * * The dynamic portion of this hook, `$status`, refers to the new completion status of the object, - * either "favorite" or "unfavorite" + * either "favorite" or "unfavorite". * * @since [version] * @@ -2022,7 +2014,7 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * Hook that fires when a student's favorite status is updated for any object. * * The dynamic portion of this hook, `$status`, refers to the new favorite status of the object, - * either "favorite" or "unfavorite" + * either "favorite" or "unfavorite". * * @since [version] * @@ -2040,7 +2032,7 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * which the student's completion status is being updated for. * * The dynamic portion of this hook, `$status`, refers to the new completion status of the object, - * either "favorite" or "unfavorite" + * either "favorite" or "unfavorite". * * @since [version] * diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 7d56563424..ab81e46f16 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -1,7 +1,7 @@ Date: Fri, 17 Mar 2023 10:49:19 +0530 Subject: [PATCH 018/522] Added helper for favorites --- includes/functions/llms.functions.course.php | 27 ------------- .../functions/llms.functions.favorite.php | 38 +++++++++++++++++++ includes/llms.functions.core.php | 3 +- 3 files changed, 40 insertions(+), 28 deletions(-) create mode 100644 includes/functions/llms.functions.favorite.php diff --git a/includes/functions/llms.functions.course.php b/includes/functions/llms.functions.course.php index 7484d50fca..61c4fefa8c 100644 --- a/includes/functions/llms.functions.course.php +++ b/includes/functions/llms.functions.course.php @@ -51,30 +51,3 @@ function get_lesson( $the_lesson = false, $args = array() ) { return new LLMS_Lesson( $the_lesson, $args ); } - -/** - * Get Favorites Count. - * - * @since [version] - * - * @param WP_Post|int|false $object_id Lesson post object or id. If `false` uses the global `$post` object. - * @return int - */ -function get_total_favorites( $object_id = false ) { - - global $wpdb; - - // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $res = $wpdb->get_results( - $wpdb->prepare( - "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta - WHERE post_id = %d AND meta_key = %s ORDER BY updated_date DESC", - $object_id, - '_favorite' - ) - ); - // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared - - return count( $res ); - -} diff --git a/includes/functions/llms.functions.favorite.php b/includes/functions/llms.functions.favorite.php new file mode 100644 index 0000000000..87b3b7b075 --- /dev/null +++ b/includes/functions/llms.functions.favorite.php @@ -0,0 +1,38 @@ +get_results( // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching + $wpdb->prepare( + "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta + WHERE post_id = %d AND meta_key = %s ORDER BY updated_date DESC", + $object_id, + '_favorite' + ) + ); + // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared + + return count( $res ); + +} diff --git a/includes/llms.functions.core.php b/includes/llms.functions.core.php index 330578bf54..44024e3cea 100644 --- a/includes/llms.functions.core.php +++ b/includes/llms.functions.core.php @@ -5,7 +5,7 @@ * @package LifterLMS/Functions * * @since 1.0.0 - * @version 6.0.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -32,6 +32,7 @@ require_once 'functions/llms.functions.quiz.php'; require_once 'functions/llms.functions.template.php'; require_once 'functions/llms.functions.user.postmeta.php'; +require_once 'functions/llms.functions.favorite.php'; if ( ! function_exists( 'llms_anonymize_string' ) ) { /** From 78ac233598e945f0423100caf5f4aee75a82d64f Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Fri, 17 Mar 2023 15:54:04 +0530 Subject: [PATCH 019/522] Added Favorite Design --- assets/scss/frontend/_main.scss | 14 ++++++++++++++ includes/llms.template.functions.php | 15 --------------- includes/llms.template.hooks.php | 1 - includes/models/model.llms.student.php | 4 ++-- templates/course/parent-course.php | 11 ++++++++++- 5 files changed, 26 insertions(+), 19 deletions(-) diff --git a/assets/scss/frontend/_main.scss b/assets/scss/frontend/_main.scss index eee0ceffe3..134ec56cbe 100644 --- a/assets/scss/frontend/_main.scss +++ b/assets/scss/frontend/_main.scss @@ -473,3 +473,17 @@ svg .llms-animated-circle { .llms-lesson-tooltip.active { display: inline-block; } + +// Favorites. +.llms-parent-course-wrapper { + display: flex; + justify-content: space-between; + + .llms-favorite-wrapper { + cursor: pointer; + + .fa-heart { + color: #FF2E2B; + } + } +} diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 618ba013ea..f85b10d3c2 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -385,21 +385,6 @@ function lifterlms_template_single_parent_course() { } } -/** - * Favorite Lesson Template Include. - * - * @since [version] - * - * @return void - */ -if ( ! function_exists( 'lifterlms_template_single_favorite' ) ) { - - function lifterlms_template_single_favorite() { - - llms_get_template( 'course/favorite.php' ); - } -} - /** * Complete Lesson Link Template Include * diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index 2203ccd750..10dc69c517 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -48,7 +48,6 @@ * @since Unknown */ add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_parent_course', 10 ); -add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_favorite', 10 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_video', 20 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_audio', 20 ); diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index bf9a3d2c8e..82d0d9c158 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1276,9 +1276,9 @@ private function insert_favorite_postmeta( $object_id ) { /** * Remove student postmeta data when lesson is unfavorited. * - * @since [version] + * @since [version] * - * @param int $object_id WP Post ID of the lesson + * @param int $object_id WP Post ID of the lesson * @return boolean */ private function remove_unfavorite_postmeta( $object_id ) { diff --git a/templates/course/parent-course.php b/templates/course/parent-course.php index 83e8d32f24..be3007d94c 100644 --- a/templates/course/parent-course.php +++ b/templates/course/parent-course.php @@ -14,5 +14,14 @@ global $post; $lesson = new LLMS_Lesson( $post ); +?> -printf( __( '', 'lifterlms' ), get_permalink( $lesson->get( 'parent_course' ) ), get_the_title( $lesson->get( 'parent_course' ) ) ); +
+ + Back to: %2$s

', 'lifterlms' ), get_permalink( $lesson->get( 'parent_course' ) ), get_the_title( $lesson->get( 'parent_course' ) ) ); + + llms_get_template( 'course/favorite.php' ); + ?> + +
From 5af16a9a3b1685d43ddf6e1286c16803c8353802 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Fri, 17 Mar 2023 17:10:26 +0530 Subject: [PATCH 020/522] =?UTF-8?q?Fixed=20favorite=20template=20design=20?= =?UTF-8?q?=F0=9F=9B=A0=EF=B8=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit when used with another template. Previous commit reverted and fixed. --- assets/scss/frontend/_main.scss | 22 +++++++++++++++------- includes/llms.template.functions.php | 15 +++++++++++++++ includes/llms.template.hooks.php | 1 + templates/course/parent-course.php | 11 +---------- 4 files changed, 32 insertions(+), 17 deletions(-) diff --git a/assets/scss/frontend/_main.scss b/assets/scss/frontend/_main.scss index 134ec56cbe..cff5dd21f1 100644 --- a/assets/scss/frontend/_main.scss +++ b/assets/scss/frontend/_main.scss @@ -475,15 +475,23 @@ svg .llms-animated-circle { } // Favorites. -.llms-parent-course-wrapper { - display: flex; - justify-content: space-between; +.llms-parent-course-link { + display: inline; - .llms-favorite-wrapper { - cursor: pointer; + + .llms-favorite-wrapper { + display: inline; + float: right; - .fa-heart { - color: #FF2E2B; + + .llms-video-wrapper { + margin-top: 10px; } } } + +.llms-favorite-wrapper { + cursor: pointer; + + .fa-heart { + color: #FF2E2B; + } +} diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index f85b10d3c2..618ba013ea 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -385,6 +385,21 @@ function lifterlms_template_single_parent_course() { } } +/** + * Favorite Lesson Template Include. + * + * @since [version] + * + * @return void + */ +if ( ! function_exists( 'lifterlms_template_single_favorite' ) ) { + + function lifterlms_template_single_favorite() { + + llms_get_template( 'course/favorite.php' ); + } +} + /** * Complete Lesson Link Template Include * diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index 10dc69c517..2203ccd750 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -48,6 +48,7 @@ * @since Unknown */ add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_parent_course', 10 ); +add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_favorite', 10 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_video', 20 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_audio', 20 ); diff --git a/templates/course/parent-course.php b/templates/course/parent-course.php index be3007d94c..83e8d32f24 100644 --- a/templates/course/parent-course.php +++ b/templates/course/parent-course.php @@ -14,14 +14,5 @@ global $post; $lesson = new LLMS_Lesson( $post ); -?> -
- - Back to: %2$s

', 'lifterlms' ), get_permalink( $lesson->get( 'parent_course' ) ), get_the_title( $lesson->get( 'parent_course' ) ) ); - - llms_get_template( 'course/favorite.php' ); - ?> - -
+printf( __( '', 'lifterlms' ), get_permalink( $lesson->get( 'parent_course' ) ), get_the_title( $lesson->get( 'parent_course' ) ) ); From 3aa835aac0b6b831eb1b53d74524836d3770950d Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Sat, 18 Mar 2023 00:48:34 +0530 Subject: [PATCH 021/522] Fixed CSS issue with favorite button when used with another element. Now a parent class is available to modify CSS. --- assets/js/llms-favorites.js | 3 +++ assets/scss/frontend/_main.scss | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index bc29a013aa..7aa6c9c4b9 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -36,6 +36,9 @@ self.favorite( $( this ) ); } ); + // Adding class in Favorite's parent + $( '.llms-favorite-wrapper' ).parent().addClass( 'llms-has-favorite' ); + }, /** diff --git a/assets/scss/frontend/_main.scss b/assets/scss/frontend/_main.scss index cff5dd21f1..d1623f280f 100644 --- a/assets/scss/frontend/_main.scss +++ b/assets/scss/frontend/_main.scss @@ -475,7 +475,7 @@ svg .llms-animated-circle { } // Favorites. -.llms-parent-course-link { +.llms-has-favorite .llms-parent-course-link { display: inline; + .llms-favorite-wrapper { From adbf385158e12ec6548582dc96ff162d67173efd Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 20 Mar 2023 14:34:40 +0530 Subject: [PATCH 022/522] Added filter to enable/disable the feature --- class-lifterlms.php | 12 ++++++++++++ includes/class.llms.frontend.assets.php | 2 +- includes/llms.template.functions.php | 4 +++- templates/content-single-lesson-before.php | 1 + 4 files changed, 17 insertions(+), 2 deletions(-) diff --git a/class-lifterlms.php b/class-lifterlms.php index 79db0f5d0d..18e6555e3c 100644 --- a/class-lifterlms.php +++ b/class-lifterlms.php @@ -24,6 +24,7 @@ * Remove deprecated class files and variables. * Move includes (file loading) into the LLMS_Loader class. * @since 5.3.0 Replace singleton code with `LLMS_Trait_Singleton`. + * @since [version] Include the Favorite filter to enable the feature. */ final class LifterLMS { @@ -418,4 +419,15 @@ public function localize() { } + /** + * Filter Hook to enable the Favorite feature. + * + * @since [version] + * + * @return boolean + */ + public function is_favorites_enabled() { + return apply_filters( 'llms_favorites_enabled', true ); + } + } diff --git a/includes/class.llms.frontend.assets.php b/includes/class.llms.frontend.assets.php index be9f2761e3..f3b66e9695 100644 --- a/includes/class.llms.frontend.assets.php +++ b/includes/class.llms.frontend.assets.php @@ -201,7 +201,7 @@ public static function enqueue_scripts() { llms()->assets->enqueue_script( 'llms-quiz' ); } - if ( is_lesson() ) { // TODO: check if favorites is enabled and enqueue script on right places. + if ( is_lesson() && true === llms()->is_favorites_enabled() ) { llms()->assets->enqueue_script( 'llms-favorites' ); } diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 618ba013ea..59fa647e64 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -396,7 +396,9 @@ function lifterlms_template_single_parent_course() { function lifterlms_template_single_favorite() { - llms_get_template( 'course/favorite.php' ); + if ( llms()->is_favorites_enabled() ) { + llms_get_template( 'course/favorite.php' ); + } } } diff --git a/templates/content-single-lesson-before.php b/templates/content-single-lesson-before.php index ef0eeebf83..393793401c 100644 --- a/templates/content-single-lesson-before.php +++ b/templates/content-single-lesson-before.php @@ -12,6 +12,7 @@ /** * @hooked - lifterlms_template_single_parent_course - 10 + * @hooked - lifterlms_template_single_favorite - 10 * @hooked - lifterlms_template_single_lesson_video - 20 * @hooked - lifterlms_template_single_lesson_audio - 20 */ From c23ad1153473835110e44ebc67ec008c67b10e42 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Tue, 21 Mar 2023 02:34:20 +0530 Subject: [PATCH 023/522] Added favorites shortcode [wip] --- .../class.llms.shortcode.favorites.php | 109 ++++++++++++++++++ includes/shortcodes/class.llms.shortcodes.php | 2 +- 2 files changed, 110 insertions(+), 1 deletion(-) create mode 100644 includes/shortcodes/class.llms.shortcode.favorites.php diff --git a/includes/shortcodes/class.llms.shortcode.favorites.php b/includes/shortcodes/class.llms.shortcode.favorites.php new file mode 100644 index 0000000000..21ef3a03a1 --- /dev/null +++ b/includes/shortcodes/class.llms.shortcode.favorites.php @@ -0,0 +1,109 @@ +get_results( + $wpdb->prepare( + "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta + WHERE meta_key = %s AND user_id = %d ORDER BY updated_date DESC", + '_favorite', + get_current_user_id() + ) + ); + + return empty( $res ) ? false : $res; + + } + + /** + * Retrieve the actual content of the shortcode. + * + * $atts & $content are both filtered before being passed to get_output() + * output is filtered so the return of get_output() doesn't need its own filter. + * + * @since [version] + * + * @return string + */ + protected function get_output() { + + $this->enqueue_script( 'llms-jquery-matchheight' ); + + ob_start(); + + // If we're outputting a "My Favorites" list and we don't have a student output login info. + if ( ! llms_get_student() ) { + + printf( + __( 'You must be logged in to view this information. Click %1$shere%2$s to login.', 'lifterlms' ), + '', + '' + ); + + } else { + + $favorites = $this->get_favorites(); + + if ( $favorites ) { + + foreach ( $favorites as $favorite ) { + + $lesson = new LLMS_Lesson( $favorite->post_id ); + + llms_get_template( + 'course/lesson-preview.php', + array( + 'lesson' => $lesson, + ) + ); + + } + } else { + + printf( '

%s

', __( 'No favorites found.', 'lifterlms' ) ); + + } + } + + return ob_get_clean(); + + } + +} + +return LLMS_Shortcode_Favorites::instance(); diff --git a/includes/shortcodes/class.llms.shortcodes.php b/includes/shortcodes/class.llms.shortcodes.php index c2387429cf..8bf2068b7b 100644 --- a/includes/shortcodes/class.llms.shortcodes.php +++ b/includes/shortcodes/class.llms.shortcodes.php @@ -68,6 +68,7 @@ public static function init() { 'LLMS_Shortcode_My_Achievements', 'LLMS_Shortcode_Registration', 'LLMS_Shortcode_User_Info', + 'LLMS_Shortcode_Favorites', ) ); @@ -79,7 +80,6 @@ public static function init() { $separator = in_array( $class, $hyphenated_file_classes, true ) ? '-' : '.'; $filename = "class{$separator}" . strtolower( str_replace( '_', $separator, $class ) ); - /** * Filters the path of the shortcode class file. * From 7dbee61573c89b7845e9d3285f07eee8b1f1d763 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Tue, 21 Mar 2023 16:08:40 +0530 Subject: [PATCH 024/522] Added shortcode attributes --- .../class.llms.shortcode.favorites.php | 25 ++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/includes/shortcodes/class.llms.shortcode.favorites.php b/includes/shortcodes/class.llms.shortcode.favorites.php index 21ef3a03a1..83b4731c98 100644 --- a/includes/shortcodes/class.llms.shortcode.favorites.php +++ b/includes/shortcodes/class.llms.shortcode.favorites.php @@ -26,6 +26,25 @@ class LLMS_Shortcode_Favorites extends LLMS_Shortcode { */ public $tag = 'lifterlms_favorites'; + /** + * Get shortcode attributes + * + * Retrieves an array of default attributes which are automatically merged + * with the user submitted attributes and passed to $this->get_output(). + * + * @since [version] + * + * @return array + */ + protected function get_default_attributes() { + + return array( + 'orderby' => 'updated_date', + 'order' => 'ASC', + 'limit' => '', + ); + } + /** * Retrieve an array of Favorites from `lifterlms_user_postmeta`. * @@ -37,10 +56,14 @@ protected function get_favorites() { global $wpdb; + $order_by = ( '' === $this->get_attribute( 'orderby' ) ) ? '' : 'ORDER BY ' . $this->get_attribute( 'orderby' ); + $order = ( '' === $this->get_attribute( 'order' ) ) ? '' : $this->get_attribute( 'order' ); + $limit = ( '' === $this->get_attribute( 'limit' ) ) ? '' : 'LIMIT ' . $this->get_attribute( 'limit' ); + $res = $wpdb->get_results( $wpdb->prepare( "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta - WHERE meta_key = %s AND user_id = %d ORDER BY updated_date DESC", + WHERE meta_key = %s AND user_id = %d $order_by $order $limit", '_favorite', get_current_user_id() ) From e2791e4ca1cdbe27ee0fc143b75b1bdb25eb86be Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Tue, 21 Mar 2023 16:45:11 +0530 Subject: [PATCH 025/522] Hiding favorites when user not logged in --- templates/course/favorite.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/templates/course/favorite.php b/templates/course/favorite.php index ab81e46f16..88169281cf 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -15,6 +15,10 @@ global $post; +if ( ! is_user_logged_in() ) { + return; +} + $lesson = new LLMS_Lesson( $post->ID ); $student = llms_get_student( get_current_user_id() ); $total_favorites = get_total_favorites( $lesson->get( 'id' ) ); @@ -23,7 +27,7 @@
- + is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> From b28a3a4c2daa9a3ea23b6ea6ab10d4e5284f7e42 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 22 Mar 2023 18:22:05 +0530 Subject: [PATCH 026/522] Added favorite event for checking existing favs *fixes bug in favorites when admin opens any completed lesson, the lesson is already favorited --- includes/class.llms.query.user.postmeta.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/includes/class.llms.query.user.postmeta.php b/includes/class.llms.query.user.postmeta.php index aa7e3cc83a..951a54a498 100644 --- a/includes/class.llms.query.user.postmeta.php +++ b/includes/class.llms.query.user.postmeta.php @@ -145,6 +145,10 @@ protected function parse_args() { 'key' => '_enrollment_trigger', 'value' => 'order_%', ), + 'favorites' => array( + 'key' => '_favorite', + 'compare' => 'IS NOT NULL', + ), ); if ( is_string( $this->arguments['types'] ) && 'all' === $this->arguments['types'] ) { From b274bef33c0f76a4b01ca0b4e0c25e34fa245980 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 29 Mar 2023 14:13:33 +0530 Subject: [PATCH 027/522] Added favorites helper in student class --- includes/models/model.llms.student.php | 30 +++++++++++++++++++ .../class.llms.shortcode.favorites.php | 21 ++++--------- 2 files changed, 36 insertions(+), 15 deletions(-) diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 82d0d9c158..12064b0c93 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -265,6 +265,36 @@ public function get_courses( $args = array() ) { } + /** + * Retrieve user's favorites based on supplied criteria. + * + * @since [version] + * + * @param string $order_by Result set ordering field. Default "date". + * @param string $order Result set order. Default "DESC". Accepts "DESC" or "ASC". + * @param integer $limit Number of favorites to return. + * @return array + */ + public function get_favorites( $order_by = '', $order = '', $limit = '' ) { + + global $wpdb; + + $order_by = ( '' === $order_by ) ? '' : 'ORDER BY ' . $order_by; + $limit = ( '' === $limit ) ? '' : 'LIMIT ' . $limit; + + $res = $wpdb->get_results( + $wpdb->prepare( + "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta + WHERE meta_key = %s AND user_id = %d $order_by $order $limit", + '_favorite', + get_current_user_id() + ) + ); + + return empty( $res ) ? false : $res; + + } + /** * Retrieve IDs of courses a user has completed * diff --git a/includes/shortcodes/class.llms.shortcode.favorites.php b/includes/shortcodes/class.llms.shortcode.favorites.php index 83b4731c98..9f590238cb 100644 --- a/includes/shortcodes/class.llms.shortcode.favorites.php +++ b/includes/shortcodes/class.llms.shortcode.favorites.php @@ -54,22 +54,13 @@ protected function get_default_attributes() { */ protected function get_favorites() { - global $wpdb; - - $order_by = ( '' === $this->get_attribute( 'orderby' ) ) ? '' : 'ORDER BY ' . $this->get_attribute( 'orderby' ); - $order = ( '' === $this->get_attribute( 'order' ) ) ? '' : $this->get_attribute( 'order' ); - $limit = ( '' === $this->get_attribute( 'limit' ) ) ? '' : 'LIMIT ' . $this->get_attribute( 'limit' ); - - $res = $wpdb->get_results( - $wpdb->prepare( - "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta - WHERE meta_key = %s AND user_id = %d $order_by $order $limit", - '_favorite', - get_current_user_id() - ) - ); + $student = llms_get_student(); + + $order_by = $this->get_attribute( 'orderby' ); + $order = $this->get_attribute( 'order' ); + $limit = $this->get_attribute( 'limit' ); - return empty( $res ) ? false : $res; + return $student->get_favorites( $order_by, $order, $limit ); } From d383ce94f81e22c5d3bbfcb49337199717a5b77f Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 29 Mar 2023 16:57:44 +0530 Subject: [PATCH 028/522] Added Favorites subpage/endpoint in student dashboard --- .../settings/class.llms.settings.accounts.php | 9 ++ includes/class.llms.student.dashboard.php | 8 ++ .../llms.functions.templates.dashboard.php | 84 ++++++++++++++++++- includes/llms.template.hooks.php | 1 + templates/myaccount/dashboard.php | 3 +- 5 files changed, 103 insertions(+), 2 deletions(-) diff --git a/includes/admin/settings/class.llms.settings.accounts.php b/includes/admin/settings/class.llms.settings.accounts.php index 86a6d629f8..02f504e53d 100644 --- a/includes/admin/settings/class.llms.settings.accounts.php +++ b/includes/admin/settings/class.llms.settings.accounts.php @@ -46,6 +46,7 @@ class LLMS_Settings_Accounts extends LLMS_Settings_Page { * Reorganized open registration setting. * Renamed "User Information Options" to "User Privacy Options". * @since 5.6.0 Added options to disable concurrent logins. + * @since [version] Added settings to view favorites. * * @return array */ @@ -180,6 +181,14 @@ public function get_settings() { 'default' => 'my-certificates', 'sanitize' => 'slug', ), + array( + 'title' => __( 'View Favorites', 'lifterlms' ), + 'desc' => __( 'List of all the student\'s favorites', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_favorites_endpoint', + 'type' => 'text', + 'default' => 'my-favorites', + 'sanitize' => 'slug', + ), array( 'title' => __( 'Notifications', 'lifterlms' ), 'desc' => __( 'View Notifications and adjust notification settings', 'lifterlms' ), diff --git a/includes/class.llms.student.dashboard.php b/includes/class.llms.student.dashboard.php index 99313c1198..ab6b1555cc 100644 --- a/includes/class.llms.student.dashboard.php +++ b/includes/class.llms.student.dashboard.php @@ -140,6 +140,7 @@ public static function get_current_tab( $return = 'data' ) { * @since 3.0.0 * @since 3.28.2 Unknown. * @since 6.0.0 Add pagination to the view-achievements and view-certificates tabs. + * @since [version] Add view-favorites tab. * * @return array */ @@ -189,6 +190,13 @@ public static function get_tabs() { 'nav_item' => true, 'title' => __( 'My Certificates', 'lifterlms' ), ), + 'view-favorites' => array( + 'content' => 'lifterlms_template_student_dashboard_my_favorites', + 'endpoint' => get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ), + 'paginate' => true, + 'nav_item' => true, + 'title' => __( 'My Favorites', 'lifterlms' ), + ), 'notifications' => array( 'content' => 'lifterlms_template_student_dashboard_my_notifications', 'endpoint' => get_option( 'lifterlms_myaccount_notifications_endpoint', 'notifications' ), diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index ed491bbab5..2e30d549b6 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -5,7 +5,7 @@ * @package LifterLMS/Functions * * @since 3.0.0 - * @version 6.3.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -275,6 +275,47 @@ function lifterlms_template_my_courses_loop( $student = null, $preview = false ) } } +if ( ! function_exists( 'lifterlms_template_my_favorites_loop' ) ) { + + /** + * Get student's favorites. + * + * @since [version] + * + * @param LLMS_Student $student Optional. LLMS_Student (current student if none supplied). Default `null`. + * @return void + */ + function lifterlms_template_my_favorites_loop( $student = null ) { + + $student = llms_get_student( $student ); + if ( ! $student ) { + return; + } + + $favorites = $student->get_favorites(); + + if ( ! $favorites ) { + + printf( '

%s

', __( 'No favorites found.', 'lifterlms' ) ); + + } else { + + foreach ( $favorites as $favorite ) { + + $lesson = new LLMS_Lesson( $favorite->post_id ); + + llms_get_template( + 'course/lesson-preview.php', + array( + 'lesson' => $lesson, + ) + ); + + } + } + + } +} if ( ! function_exists( 'lifterlms_template_my_memberships_loop' ) ) { @@ -503,6 +544,47 @@ function lifterlms_template_student_dashboard_my_courses( $preview = false ) { } } +if ( ! function_exists( 'lifterlms_template_student_dashboard_my_favorites' ) ) { + + /** + * Template for My Favorites section on dashboard index. + * + * @since [version] + * + * @param bool $preview Optional. If true, outputs a short list of favorites. Default `false`. + * @return void + */ + function lifterlms_template_student_dashboard_my_favorites( $preview = false ) { + + $student = llms_get_student(); + if ( ! $student ) { + return; + } + + $more = false; + if ( $preview && LLMS_Student_Dashboard::is_endpoint_enabled( 'view-favorites' ) ) { + $more = array( + 'url' => llms_get_endpoint_url( 'view-favorites', '', llms_get_page_url( 'myaccount' ) ), + 'text' => __( 'View All My Favorites', 'lifterlms' ), + ); + } + + ob_start(); + lifterlms_template_my_favorites_loop( $student, $preview ); + + llms_get_template( + 'myaccount/dashboard-section.php', + array( + 'action' => 'my_favorites', + 'slug' => 'llms-my-favorites', + 'title' => $preview ? __( 'My Favorites', 'lifterlms' ) : '', + 'content' => ob_get_clean(), + 'more' => $more, + ) + ); + + } +} if ( ! function_exists( 'lifterlms_template_student_dashboard_my_grades' ) ) { diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index 2203ccd750..112a29d8dc 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -169,6 +169,7 @@ add_action( 'llms_achievement_content', 'llms_the_achievement', 10 ); add_action( 'llms_certificate_preview', 'llms_the_certificate_preview', 10 ); add_action( 'lifterlms_student_dashboard_index', 'lifterlms_template_student_dashboard_my_memberships', 40 ); +add_action( 'lifterlms_student_dashboard_index', 'lifterlms_template_student_dashboard_my_favorites', 50 ); add_action( 'llms_my_grades_course_table', 'lifterlms_template_student_dashboard_my_grades_table', 10, 2 ); diff --git a/templates/myaccount/dashboard.php b/templates/myaccount/dashboard.php index ee06da4894..a889e06fe0 100644 --- a/templates/myaccount/dashboard.php +++ b/templates/myaccount/dashboard.php @@ -5,7 +5,7 @@ * @package LifterLMS/Templates * * @since 1.0.0 - * @version 3.14.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -26,6 +26,7 @@ * @hooked lifterlms_template_student_dashboard_my_achievements - 20 * @hooked lifterlms_template_student_dashboard_my_certificates - 30 * @hooked lifterlms_template_student_dashboard_my_memberships - 40 + * @hooked lifterlms_template_student_dashboard_my_favorites - 50 */ do_action( 'lifterlms_student_dashboard_index', true ); From 88cd9cbbedcd7b8fab4bbb4a2c944ad631d14aac Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 29 Mar 2023 17:22:51 +0530 Subject: [PATCH 029/522] Disabling favorites endpoint if favorites disabled --- includes/class.llms.student.dashboard.php | 2 +- includes/functions/llms.functions.templates.dashboard.php | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/class.llms.student.dashboard.php b/includes/class.llms.student.dashboard.php index ab6b1555cc..a71808a25a 100644 --- a/includes/class.llms.student.dashboard.php +++ b/includes/class.llms.student.dashboard.php @@ -192,7 +192,7 @@ public static function get_tabs() { ), 'view-favorites' => array( 'content' => 'lifterlms_template_student_dashboard_my_favorites', - 'endpoint' => get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ), + 'endpoint' => llms()->is_favorites_enabled() ? get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ) : '', 'paginate' => true, 'nav_item' => true, 'title' => __( 'My Favorites', 'lifterlms' ), diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 2e30d549b6..f3928b5f24 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -557,7 +557,8 @@ function lifterlms_template_student_dashboard_my_courses( $preview = false ) { function lifterlms_template_student_dashboard_my_favorites( $preview = false ) { $student = llms_get_student(); - if ( ! $student ) { + + if ( ! $student || ! llms()->is_favorites_enabled() ) { return; } From 37ee724d5092bd75f2d6461485aebc0a0846cc2a Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 29 Mar 2023 17:39:41 +0530 Subject: [PATCH 030/522] Disabling admin favorite settings via filter. --- includes/admin/settings/class.llms.settings.accounts.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/admin/settings/class.llms.settings.accounts.php b/includes/admin/settings/class.llms.settings.accounts.php index 02f504e53d..c50332a7e1 100644 --- a/includes/admin/settings/class.llms.settings.accounts.php +++ b/includes/admin/settings/class.llms.settings.accounts.php @@ -46,7 +46,7 @@ class LLMS_Settings_Accounts extends LLMS_Settings_Page { * Reorganized open registration setting. * Renamed "User Information Options" to "User Privacy Options". * @since 5.6.0 Added options to disable concurrent logins. - * @since [version] Added settings to view favorites. + * @since [version] Added settings for favorites endpoint. * * @return array */ @@ -188,6 +188,7 @@ public function get_settings() { 'type' => 'text', 'default' => 'my-favorites', 'sanitize' => 'slug', + 'disabled' => ! llms()->is_favorites_enabled() ? true : false, ), array( 'title' => __( 'Notifications', 'lifterlms' ), From 389945cfde929c1c921729f783a7ff5f04ad44f8 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 30 Mar 2023 16:46:51 +0530 Subject: [PATCH 031/522] Added favorites in lesson view --- assets/scss/frontend/_main.scss | 4 ++++ includes/class.llms.frontend.assets.php | 4 ++-- includes/functions/llms.functions.person.php | 16 ++++++++-------- includes/llms.template.functions.php | 13 +++++++++++-- templates/course/favorite.php | 8 ++++---- templates/course/lesson-preview.php | 4 +++- 6 files changed, 32 insertions(+), 17 deletions(-) diff --git a/assets/scss/frontend/_main.scss b/assets/scss/frontend/_main.scss index d1623f280f..804b905812 100644 --- a/assets/scss/frontend/_main.scss +++ b/assets/scss/frontend/_main.scss @@ -495,3 +495,7 @@ svg .llms-animated-circle { color: #FF2E2B; } } + +.llms-syllabus-wrapper .llms-favorite-wrapper { + text-align: left; +} diff --git a/includes/class.llms.frontend.assets.php b/includes/class.llms.frontend.assets.php index f3b66e9695..37939eb2f6 100644 --- a/includes/class.llms.frontend.assets.php +++ b/includes/class.llms.frontend.assets.php @@ -166,7 +166,7 @@ public static function enqueue_styles() { * Moved inline scripts to `enqueue_inline_scripts()`. * @since 5.0.0 Enqueue locale data and dependencies on account and checkout pages for searchable dropdowns for country & state. * Remove password strength inline enqueue. - * @since [version] Enqueue `llms-favorites` script. + * @since [version] Enqueue `llms-favorites` script on lesson and course page. * * @return void */ @@ -201,7 +201,7 @@ public static function enqueue_scripts() { llms()->assets->enqueue_script( 'llms-quiz' ); } - if ( is_lesson() && true === llms()->is_favorites_enabled() ) { + if ( ( is_lesson() || is_course() ) && true === llms()->is_favorites_enabled() ) { llms()->assets->enqueue_script( 'llms-favorites' ); } diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index b06313e17b..664cb949f5 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -325,7 +325,7 @@ function llms_is_user_enrolled( $user_id, $product_id, $relation = 'all', $use_c * * @param int $user_id WP User ID. * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param int $object_type Object type [lesson|section|course|track]. + * @param string $object_type Object type [lesson|section|course|track]. * @param string $trigger String describing the event that triggered marking the object as complete. * @return boolean */ @@ -343,7 +343,7 @@ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'uns * * @param int $user_id WP User ID. * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param int $object_type Object type [lesson|section|course|track]. + * @param string $object_type Object type [lesson|section|course|track]. * @param string $trigger String describing the event that triggered marking the object as incomplete. * @return boolean */ @@ -359,9 +359,9 @@ function llms_mark_incomplete( $user_id, $object_id, $object_type, $trigger = 'u * * @see LLMS_Student->mark_favorite() * - * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param int $object_type Object type [lesson|section|course|track]. + * @param int $user_id WP User ID. + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param string $object_type Object type [lesson|section|course|track]. * @return boolean */ function llms_mark_favorite( $user_id, $object_id, $object_type ) { @@ -376,9 +376,9 @@ function llms_mark_favorite( $user_id, $object_id, $object_type ) { * * @see LLMS_Student->mark_unfavorite() * - * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param int $object_type Object type [lesson|section|course|track]. + * @param int $user_id WP User ID. + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param string $object_type Object type [lesson|section|course|track]. * @return boolean */ function llms_mark_unfavorite( $user_id, $object_id, $object_type ) { diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 59fa647e64..19e1a0d156 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -390,14 +390,23 @@ function lifterlms_template_single_parent_course() { * * @since [version] * + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param string $object_type Object type [lesson|section|course|track]. * @return void */ if ( ! function_exists( 'lifterlms_template_single_favorite' ) ) { - function lifterlms_template_single_favorite() { + function lifterlms_template_single_favorite( $object_id = null, $object_type = 'lesson' ) { if ( llms()->is_favorites_enabled() ) { - llms_get_template( 'course/favorite.php' ); + + llms_get_template( + 'course/favorite.php', + array( + 'object_id' => $object_id, + 'object_type' => $object_type, + ) + ); } } } diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 88169281cf..5899c2c01b 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -8,8 +8,8 @@ * * @since [version] * - * @var LLMS_Lesson $lesson The lesson object. - * @var LLMS_Student $student A LLMS_Student object. + * @var int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @var string $object_type Object type [lesson|section|course|track]. */ defined( 'ABSPATH' ) || exit; @@ -19,7 +19,7 @@ return; } -$lesson = new LLMS_Lesson( $post->ID ); +$lesson = new LLMS_Lesson( ( null === $object_id || '' === $object_id ) ? $post->ID : $object_id ); $student = llms_get_student( get_current_user_id() ); $total_favorites = get_total_favorites( $lesson->get( 'id' ) ); ?> @@ -34,7 +34,7 @@ - + diff --git a/templates/course/lesson-preview.php b/templates/course/lesson-preview.php index aa1bd906a7..698396e6b5 100644 --- a/templates/course/lesson-preview.php +++ b/templates/course/lesson-preview.php @@ -9,7 +9,8 @@ * @since 3.19.2 Unknown. * @since 4.4.0 Use the passed `$order` param if available, in favor of retrieving the lesson's order post meta. * @since 5.7.0 Replaced the call to the deprecated `LLMS_Lesson::get_order()` method with `LLMS_Lesson::get( 'order' )`. - * @version 5.7.0 + * @since [version] Added Favorites function `lifterlms_template_single_favorite()`. + * @version [version] * * @var LLMS_Lesson $lesson The lesson object. * @var string $pre_text The text to display before the lesson. @@ -46,6 +47,7 @@
get( 'id' ) ); ?>
+ get( 'id' ) ); ?> get( 'id' ) ) ) : ?>
get( 'id' ) ); ?>
From 70b599530218cafdc39c13aadec6f4d9ea215986 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 30 Mar 2023 16:57:40 +0530 Subject: [PATCH 032/522] Added dummy favorite for logged out user --- templates/course/favorite.php | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 5899c2c01b..4db37d5e51 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -15,10 +15,6 @@ global $post; -if ( ! is_user_logged_in() ) { - return; -} - $lesson = new LLMS_Lesson( ( null === $object_id || '' === $object_id ) ? $post->ID : $object_id ); $student = llms_get_student( get_current_user_id() ); $total_favorites = get_total_favorites( $lesson->get( 'id' ) ); @@ -28,17 +24,25 @@ - is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> + + + + + + + is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> + + + - - + - + + - - + - + From afd5b4e431e25b257cf216e62b9bfdc2b3a94e20 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 12 Apr 2023 14:51:08 +0530 Subject: [PATCH 033/522] Action validation for LifterLMS Labs --- includes/llms.template.functions.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 19e1a0d156..2dc0f31e53 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -398,7 +398,7 @@ function lifterlms_template_single_parent_course() { function lifterlms_template_single_favorite( $object_id = null, $object_type = 'lesson' ) { - if ( llms()->is_favorites_enabled() ) { + if ( llms()->is_favorites_enabled() && has_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_favorite' ) ) { llms_get_template( 'course/favorite.php', From 7784735ea2e03dbdd3419f636109da5e12816cea Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 20 Apr 2023 17:09:36 +0530 Subject: [PATCH 034/522] Minor fixes --- includes/llms.template.functions.php | 6 +++--- includes/llms.template.hooks.php | 2 +- templates/content-single-lesson-before.php | 2 +- templates/course/lesson-preview.php | 6 ++++-- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 2dc0f31e53..1760c4ca08 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -394,11 +394,11 @@ function lifterlms_template_single_parent_course() { * @param string $object_type Object type [lesson|section|course|track]. * @return void */ -if ( ! function_exists( 'lifterlms_template_single_favorite' ) ) { +if ( ! function_exists( 'lifterlms_template_favorite' ) ) { - function lifterlms_template_single_favorite( $object_id = null, $object_type = 'lesson' ) { + function lifterlms_template_favorite( $object_id = null, $object_type = 'lesson' ) { - if ( llms()->is_favorites_enabled() && has_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_favorite' ) ) { + if ( llms()->is_favorites_enabled() ) { llms_get_template( 'course/favorite.php', diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index 112a29d8dc..eb8b01193c 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -48,7 +48,7 @@ * @since Unknown */ add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_parent_course', 10 ); -add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_favorite', 10 ); +add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_favorite', 10 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_video', 20 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_audio', 20 ); diff --git a/templates/content-single-lesson-before.php b/templates/content-single-lesson-before.php index 393793401c..9610309e7a 100644 --- a/templates/content-single-lesson-before.php +++ b/templates/content-single-lesson-before.php @@ -12,7 +12,7 @@ /** * @hooked - lifterlms_template_single_parent_course - 10 - * @hooked - lifterlms_template_single_favorite - 10 + * @hooked - lifterlms_template_favorite - 10 * @hooked - lifterlms_template_single_lesson_video - 20 * @hooked - lifterlms_template_single_lesson_audio - 20 */ diff --git a/templates/course/lesson-preview.php b/templates/course/lesson-preview.php index 698396e6b5..9b0bab6d24 100644 --- a/templates/course/lesson-preview.php +++ b/templates/course/lesson-preview.php @@ -9,7 +9,7 @@ * @since 3.19.2 Unknown. * @since 4.4.0 Use the passed `$order` param if available, in favor of retrieving the lesson's order post meta. * @since 5.7.0 Replaced the call to the deprecated `LLMS_Lesson::get_order()` method with `LLMS_Lesson::get( 'order' )`. - * @since [version] Added Favorites function `lifterlms_template_single_favorite()`. + * @since [version] Added Favorites function `lifterlms_template_favorite()`. * @version [version] * * @var LLMS_Lesson $lesson The lesson object. @@ -47,7 +47,9 @@
get( 'id' ) ); ?>
- get( 'id' ) ); ?> + + get( 'id' ) ); ?> + get( 'id' ) ) ) : ?>
get( 'id' ) ); ?>
From 1ed588582722634839fba186838e85a52141ad66 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 20 Apr 2023 18:29:02 +0530 Subject: [PATCH 035/522] Added support for LifterLabs switch --- templates/course/lesson-preview.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/course/lesson-preview.php b/templates/course/lesson-preview.php index 9b0bab6d24..ef3fe8dd4b 100644 --- a/templates/course/lesson-preview.php +++ b/templates/course/lesson-preview.php @@ -47,7 +47,7 @@
get( 'id' ) ); ?>
- + get( 'id' ) ); ?> get( 'id' ) ) ) : ?> From a6f76f81fa0a26c28b2f5eb843bb3b7ca9abf95b Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Tue, 25 Apr 2023 18:43:09 +0530 Subject: [PATCH 036/522] CS Fixes --- includes/class.llms.query.user.postmeta.php | 4 ++-- includes/models/model.llms.student.php | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/class.llms.query.user.postmeta.php b/includes/class.llms.query.user.postmeta.php index 951a54a498..2ec0baa229 100644 --- a/includes/class.llms.query.user.postmeta.php +++ b/includes/class.llms.query.user.postmeta.php @@ -145,8 +145,8 @@ protected function parse_args() { 'key' => '_enrollment_trigger', 'value' => 'order_%', ), - 'favorites' => array( - 'key' => '_favorite', + 'favorites' => array( + 'key' => '_favorite', 'compare' => 'IS NOT NULL', ), ); diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 12064b0c93..7eeee5c50f 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -282,6 +282,7 @@ public function get_favorites( $order_by = '', $order = '', $limit = '' ) { $order_by = ( '' === $order_by ) ? '' : 'ORDER BY ' . $order_by; $limit = ( '' === $limit ) ? '' : 'LIMIT ' . $limit; + // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared $res = $wpdb->get_results( $wpdb->prepare( "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta From 09760e6ab8e85add43cdf0f2a395f4d32dc31ab5 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 26 Apr 2023 16:36:51 +0530 Subject: [PATCH 037/522] Fixed Unit Tests for favorites --- tests/phpunit/unit-tests/class-llms-test-query.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/phpunit/unit-tests/class-llms-test-query.php b/tests/phpunit/unit-tests/class-llms-test-query.php index 1a01e2572d..09463d96e1 100644 --- a/tests/phpunit/unit-tests/class-llms-test-query.php +++ b/tests/phpunit/unit-tests/class-llms-test-query.php @@ -81,6 +81,7 @@ public function test_add_endpoints() { 'view-memberships' => 'lifterlms_myaccount_memberships_endpoint', 'view-achievements' => 'lifterlms_myaccount_achievements_endpoint', 'view-certificates' => 'lifterlms_myaccount_certificates_endpoint', + 'view-favorites' => 'lifterlms_myaccount_favorites_endpoint', 'notifications' => 'lifterlms_myaccount_notifications_endpoint', 'edit-account' => 'lifterlms_myaccount_edit_account_endpoint', 'redeem-voucher' => 'lifterlms_myaccount_redeem_vouchers_endpoint', @@ -93,6 +94,7 @@ public function test_add_endpoints() { 'view-memberships' => 'ਵੇਖੋ-ਸਦੱਸਤਾ', // Punjabi. 'view-achievements' => 'nailiyyətlər', // Azerbaijani. 'view-certificates' => 'ເບິ່ງໃບຢັ້ງຢືນ', // Lao. + 'view-favorites' => '즐겨찾기', // Korean. 'notifications' => '通知', // Chinese (Simplified). 'edit-account' => 'חשבון-עריכה', // Hebrew. 'redeem-voucher' => 'چھڑانا', // Urdu. From 29984c6bd1b8ffa83ab5bd36fbbc240cc954cab3 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 26 Apr 2023 23:16:33 +0530 Subject: [PATCH 038/522] unit test fix --- .../admin/settings/class-llms-test-settings-accounts.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/phpunit/unit-tests/admin/settings/class-llms-test-settings-accounts.php b/tests/phpunit/unit-tests/admin/settings/class-llms-test-settings-accounts.php index e4131568d3..dd31b8af71 100644 --- a/tests/phpunit/unit-tests/admin/settings/class-llms-test-settings-accounts.php +++ b/tests/phpunit/unit-tests/admin/settings/class-llms-test-settings-accounts.php @@ -87,6 +87,10 @@ protected function get_mock_settings() { 'my-certificates', 'custom-endpoint-certificates', ), + 'lifterlms_myaccount_favorites_endpoint' => array( + 'my-favorites', + 'custom-endpoint-favorites', + ), 'lifterlms_myaccount_notifications_endpoint' => array( 'notifications', 'custom-endpoint-notifications', From 7bb81fd8e04330d6fee5dbd93eed22a640e43271 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 21 Jun 2023 16:42:53 +0530 Subject: [PATCH 039/522] whole wrapper clickable for favorites --- assets/js/llms-favorites.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index 7aa6c9c4b9..c694daee9f 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -31,9 +31,10 @@ var self = this; // Favorite clicked - $( '.llms-favorite-wrapper' ).on( 'click', '.llms-heart-btn', function( e ) { + $( '.llms-favorite-wrapper' ).on( 'click', function( e ) { e.preventDefault(); - self.favorite( $( this ) ); + let $btn = $( this ).find( '.llms-heart-btn' ); + self.favorite( $btn ); } ); // Adding class in Favorite's parent From 09fbb232d64e43f94fc14930d1bf337906b112dc Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 22 Jun 2023 12:52:23 +0530 Subject: [PATCH 040/522] favs grouped under respective course --- .../llms.functions.templates.dashboard.php | 37 ++++++++++++++++++- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index a771411ef6..27f337adda 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -313,9 +313,27 @@ function lifterlms_template_my_favorites_loop( $student = null ) { } else { - foreach ( $favorites as $favorite ) { + // Adding Parent Course IDs in Favorites for each lesson. + foreach ( $favorites as $key => $favorite ) { + $parent_course = get_post_meta( $favorite->post_id, '_llms_parent_course', true ); + $favorite->parent_course = $parent_course; + } + + // Grouping Favorites by Parent Course ID. + $favorites = array_reduce( + $favorites, + function ( $carry, $item ) { + $carry[ $item->parent_course ][] = $item; + return $carry; + }, + array() + ); - $lesson = new LLMS_Lesson( $favorite->post_id ); + // Printing Favorite Lessons under each Parent Course. + foreach ( $favorites as $course => $lessons ) { + + // Get Course Name. + $lesson = new LLMS_Lesson( $course ); llms_get_template( 'course/lesson-preview.php', @@ -324,6 +342,21 @@ function lifterlms_template_my_favorites_loop( $student = null ) { ) ); + echo '
    '; + foreach ( $lessons as $lesson ) { + + $lesson = new LLMS_Lesson( $lesson->post_id ); + echo '
  • '; + llms_get_template( + 'course/lesson-preview.php', + array( + 'lesson' => $lesson, + ) + ); + echo '
  • '; + } + echo '
'; + } } From b001128e7824e59f9d73bba11929a13ce985813f Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 22 Jun 2023 13:21:28 +0530 Subject: [PATCH 041/522] removed TODOs --- templates/course/favorite.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 4db37d5e51..da6fe95d91 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -32,12 +32,10 @@ is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> - - From efeef1aa3db255040e48382458c4fa75510a387c Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Thu, 22 Jun 2023 13:37:36 +0530 Subject: [PATCH 042/522] equalize dashboard and shortcode output --- .../llms.functions.templates.dashboard.php | 6 ++--- .../class.llms.shortcode.favorites.php | 22 +------------------ 2 files changed, 4 insertions(+), 24 deletions(-) diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 27f337adda..0139690cac 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -298,14 +298,14 @@ function lifterlms_template_my_courses_loop( $student = null, $preview = false ) * @param LLMS_Student $student Optional. LLMS_Student (current student if none supplied). Default `null`. * @return void */ - function lifterlms_template_my_favorites_loop( $student = null ) { + function lifterlms_template_my_favorites_loop( $student = null, $favorites = null ) { $student = llms_get_student( $student ); if ( ! $student ) { return; } - $favorites = $student->get_favorites(); + $favorites = $favorites ?? $student->get_favorites(); if ( ! $favorites ) { @@ -630,7 +630,7 @@ function lifterlms_template_student_dashboard_my_favorites( $preview = false ) { } ob_start(); - lifterlms_template_my_favorites_loop( $student, $preview ); + lifterlms_template_my_favorites_loop( $student ); llms_get_template( 'myaccount/dashboard-section.php', diff --git a/includes/shortcodes/class.llms.shortcode.favorites.php b/includes/shortcodes/class.llms.shortcode.favorites.php index 9f590238cb..2657d975e5 100644 --- a/includes/shortcodes/class.llms.shortcode.favorites.php +++ b/includes/shortcodes/class.llms.shortcode.favorites.php @@ -76,8 +76,6 @@ protected function get_favorites() { */ protected function get_output() { - $this->enqueue_script( 'llms-jquery-matchheight' ); - ob_start(); // If we're outputting a "My Favorites" list and we don't have a student output login info. @@ -93,25 +91,7 @@ protected function get_output() { $favorites = $this->get_favorites(); - if ( $favorites ) { - - foreach ( $favorites as $favorite ) { - - $lesson = new LLMS_Lesson( $favorite->post_id ); - - llms_get_template( - 'course/lesson-preview.php', - array( - 'lesson' => $lesson, - ) - ); - - } - } else { - - printf( '

%s

', __( 'No favorites found.', 'lifterlms' ) ); - - } + lifterlms_template_my_favorites_loop( get_current_user_id(), $favorites ); } return ob_get_clean(); From 9b55935c4c294d6cdcc7242b6ebaf4eb7c46f4c1 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 26 Jul 2023 15:29:49 +0530 Subject: [PATCH 043/522] Added enable/disable control for favs --- class-lifterlms.php | 7 +++++-- .../admin/settings/class.llms.settings.general.php | 11 ++++++++++- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/class-lifterlms.php b/class-lifterlms.php index f265346cd4..408ab94e80 100644 --- a/class-lifterlms.php +++ b/class-lifterlms.php @@ -5,7 +5,7 @@ * @package LifterLMS/Main * * @since 1.0.0 - * @version 7.2.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -429,7 +429,10 @@ public function localize() { * @return boolean */ public function is_favorites_enabled() { - return apply_filters( 'llms_favorites_enabled', true ); + + $favorite_enabled = llms_parse_bool( get_option( 'lifterlms_favorites', 'no' ) ); + + return apply_filters( 'llms_favorites_enabled', $favorite_enabled ); } } diff --git a/includes/admin/settings/class.llms.settings.general.php b/includes/admin/settings/class.llms.settings.general.php index b93ed7790a..f1a5f897d9 100644 --- a/includes/admin/settings/class.llms.settings.general.php +++ b/includes/admin/settings/class.llms.settings.general.php @@ -5,7 +5,7 @@ * @package LifterLMS/Admin/Settings/Classes * * @since 1.0.0 - * @version 6.0.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -45,6 +45,7 @@ public function __construct() { * @since 3.13.0 Unknown. * @since 5.6.0 use LLMS_Roles::get_all_role_names() to retrieve the list of roles who can bypass enrollments. * Add content protection setting. + * @since [version] Added settings for enabling/disabling favorites. * * @return array */ @@ -72,6 +73,14 @@ public function get_settings() { ), ); + $settings[] = array( + 'title' => __( 'Lesson Favorites', 'lifterlms' ), + 'desc' => __( 'Enabling this setting allows students to mark a lesson as "favorite".', 'lifterlms' ), + 'id' => 'lifterlms_favorites', + 'default' => 'no', + 'type' => 'checkbox', + ); + $settings[] = array( 'id' => 'section_features', 'type' => 'sectionend', From 5621a21547d60170a55586ce88ac5d711ac30fdd Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Wed, 26 Jul 2023 19:16:46 +0530 Subject: [PATCH 044/522] Added changelogs and docblock fixes --- .changelogs/feature_favorite-1.yml | 3 +++ .changelogs/feature_favorite-2.yml | 4 ++++ .changelogs/feature_favorite-3.yml | 4 ++++ .changelogs/feature_favorite.yml | 3 +++ class-lifterlms.php | 9 ++++++++- includes/admin/settings/class.llms.settings.accounts.php | 2 +- includes/assets/llms-assets-scripts.php | 2 +- includes/class.llms.ajax.php | 3 ++- includes/class.llms.frontend.assets.php | 2 +- includes/class.llms.query.user.postmeta.php | 7 ++++--- includes/class.llms.student.dashboard.php | 2 +- includes/functions/llms.functions.course.php | 2 +- includes/functions/llms.functions.person.php | 2 +- includes/llms.template.functions.php | 2 +- includes/models/model.llms.student.php | 6 +++--- includes/shortcodes/class.llms.shortcode.favorites.php | 4 ++-- includes/shortcodes/class.llms.shortcodes.php | 3 ++- templates/myaccount/dashboard.php | 2 +- 18 files changed, 43 insertions(+), 19 deletions(-) create mode 100644 .changelogs/feature_favorite-1.yml create mode 100644 .changelogs/feature_favorite-2.yml create mode 100644 .changelogs/feature_favorite-3.yml create mode 100644 .changelogs/feature_favorite.yml diff --git a/.changelogs/feature_favorite-1.yml b/.changelogs/feature_favorite-1.yml new file mode 100644 index 0000000000..8f8159c56c --- /dev/null +++ b/.changelogs/feature_favorite-1.yml @@ -0,0 +1,3 @@ +significance: minor +type: dev +entry: Added 'favorites' in User postmeta for getting all user's favorites. diff --git a/.changelogs/feature_favorite-2.yml b/.changelogs/feature_favorite-2.yml new file mode 100644 index 0000000000..a86c9048c8 --- /dev/null +++ b/.changelogs/feature_favorite-2.yml @@ -0,0 +1,4 @@ +significance: minor +type: dev +entry: Added filter `lifterlms_single_course_syllabus_lesson_favorite` for + disabling favorites in syllabus view. diff --git a/.changelogs/feature_favorite-3.yml b/.changelogs/feature_favorite-3.yml new file mode 100644 index 0000000000..ee9fdfd87c --- /dev/null +++ b/.changelogs/feature_favorite-3.yml @@ -0,0 +1,4 @@ +significance: minor +type: dev +entry: Added filter `llms_is_$object_type_favorite` to change object's (lesson, + student, course) favorite boolean value. diff --git a/.changelogs/feature_favorite.yml b/.changelogs/feature_favorite.yml new file mode 100644 index 0000000000..55f9764807 --- /dev/null +++ b/.changelogs/feature_favorite.yml @@ -0,0 +1,3 @@ +significance: minor +type: dev +entry: Added filter `llms_favorites_enabled` to enable/disable Favorites feature. diff --git a/class-lifterlms.php b/class-lifterlms.php index 408ab94e80..6462d75cc7 100644 --- a/class-lifterlms.php +++ b/class-lifterlms.php @@ -24,7 +24,7 @@ * Remove deprecated class files and variables. * Move includes (file loading) into the LLMS_Loader class. * @since 5.3.0 Replace singleton code with `LLMS_Trait_Singleton`. - * @since [version] Include the Favorite filter to enable the feature. + * @since [version] Added `is_favorites_enabled` to check favorites status. */ final class LifterLMS { @@ -432,6 +432,13 @@ public function is_favorites_enabled() { $favorite_enabled = llms_parse_bool( get_option( 'lifterlms_favorites', 'no' ) ); + /** + * Filter to enable/disable the Favorite feature. + * + * @since [version] + * + * @param boolean $favorite_enabled True if favorites are enabled, false otherwise. + */ return apply_filters( 'llms_favorites_enabled', $favorite_enabled ); } diff --git a/includes/admin/settings/class.llms.settings.accounts.php b/includes/admin/settings/class.llms.settings.accounts.php index c50332a7e1..abfcb4a686 100644 --- a/includes/admin/settings/class.llms.settings.accounts.php +++ b/includes/admin/settings/class.llms.settings.accounts.php @@ -5,7 +5,7 @@ * @package LifterLMS/Admin/Settings/Classes * * @since 1.0.0 - * @version 5.6.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; diff --git a/includes/assets/llms-assets-scripts.php b/includes/assets/llms-assets-scripts.php index 434485c026..f9c9046816 100644 --- a/includes/assets/llms-assets-scripts.php +++ b/includes/assets/llms-assets-scripts.php @@ -18,7 +18,7 @@ * @package LifterLMS/Assets * * @since 4.4.0 - * @version 7.0.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; diff --git a/includes/class.llms.ajax.php b/includes/class.llms.ajax.php index 96bb3bd45c..e4e21b3034 100644 --- a/includes/class.llms.ajax.php +++ b/includes/class.llms.ajax.php @@ -5,7 +5,7 @@ * @package LifterLMS/Classes * * @since 1.0.0 - * @version 5.9.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -20,6 +20,7 @@ * - `LLMS_AJAX::check_voucher_duplicate()` method. * - `LLMS_AJAX::get_ajax_data()` method. * - `LLMS_AJAX::register_script()` method. + * @since [version] Added method `favorite_object` to Add Favorite / Unfavorite Postmeta for an object. */ class LLMS_AJAX { diff --git a/includes/class.llms.frontend.assets.php b/includes/class.llms.frontend.assets.php index 37939eb2f6..8e08b0d1c3 100644 --- a/includes/class.llms.frontend.assets.php +++ b/includes/class.llms.frontend.assets.php @@ -5,7 +5,7 @@ * @package LifterLMS/Classes * * @since 1.0.0 - * @version 7.0.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; diff --git a/includes/class.llms.query.user.postmeta.php b/includes/class.llms.query.user.postmeta.php index 2ec0baa229..b4cc0759bf 100644 --- a/includes/class.llms.query.user.postmeta.php +++ b/includes/class.llms.query.user.postmeta.php @@ -5,7 +5,7 @@ * @package LifterLMS/Classes * * @since 3.15.0 - * @version 6.0.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -14,7 +14,7 @@ * LifterLMS User Postmeta Query * * @since 3.15.0 - * @version 3.15.0 + * @version [version] */ class LLMS_Query_User_Postmeta extends LLMS_Database_Query { @@ -87,7 +87,8 @@ public function get_metas() { * * @return void * @since 3.15.0 - * @version 3.15.0 + * @since [version] Added 'Favorites' event. + * @version [version] */ protected function parse_args() { diff --git a/includes/class.llms.student.dashboard.php b/includes/class.llms.student.dashboard.php index a71808a25a..f6660f9f98 100644 --- a/includes/class.llms.student.dashboard.php +++ b/includes/class.llms.student.dashboard.php @@ -5,7 +5,7 @@ * @package LifterLMS/Classes * * @since 3.0.0 - * @version 6.0.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; diff --git a/includes/functions/llms.functions.course.php b/includes/functions/llms.functions.course.php index 61c4fefa8c..f987c74f24 100644 --- a/includes/functions/llms.functions.course.php +++ b/includes/functions/llms.functions.course.php @@ -5,7 +5,7 @@ * @package LifterLMS/Functions * * @since Unknown - * @version [version] + * @version 3.37.13 */ defined( 'ABSPATH' ) || exit; diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index 16c1d2aa3e..3d470bf550 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -7,7 +7,7 @@ * @package LifterLMS/Functions * * @since 1.0.0 - * @version 7.1.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index a40436c56c..5460244580 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -5,7 +5,7 @@ * @package LifterLMS/Functions/Templates * * @since 1.0.0 - * @version 7.1.2 + * @version [version] */ defined( 'ABSPATH' ) || exit; diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 7eeee5c50f..1497d12b56 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -5,7 +5,7 @@ * @package LifterLMS/Models/Classes * * @since 2.2.3 - * @version 6.0.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -27,7 +27,7 @@ * Added new filter to allow customization of object completion data. * @since 5.2.0 Changed the date to be relative to the local time zone in `get_registration_date`. * @since 6.0.0 Removed the deprecated `llms_user_removed_from_membership_level` action hook from the `LLMS_Student::unenroll()` method. - * @since [version] Added the logic to add and remove lesson favoritism. + * @since [version] Added the logic to add and remove lesson favorite. */ class LLMS_Student extends LLMS_Abstract_User_Data { @@ -1933,7 +1933,7 @@ public function is_favorite( $object_id, $object_type = 'lesson' ) { $ret = $query->has_results(); /** - * Filter object favorite boolean value prior to returning + * Filter object favorite boolean value prior to returning. * * The dynamic portion of this filter, `{$object_type}`, refers to the Lesson, Course or Instructor. * diff --git a/includes/shortcodes/class.llms.shortcode.favorites.php b/includes/shortcodes/class.llms.shortcode.favorites.php index 2657d975e5..9463e6a91b 100644 --- a/includes/shortcodes/class.llms.shortcode.favorites.php +++ b/includes/shortcodes/class.llms.shortcode.favorites.php @@ -20,14 +20,14 @@ class LLMS_Shortcode_Favorites extends LLMS_Shortcode { /** - * Shortcode tag + * Shortcode tag. * * @var string */ public $tag = 'lifterlms_favorites'; /** - * Get shortcode attributes + * Get shortcode attributes. * * Retrieves an array of default attributes which are automatically merged * with the user submitted attributes and passed to $this->get_output(). diff --git a/includes/shortcodes/class.llms.shortcodes.php b/includes/shortcodes/class.llms.shortcodes.php index 9b49b6f61f..e58a24ca48 100644 --- a/includes/shortcodes/class.llms.shortcodes.php +++ b/includes/shortcodes/class.llms.shortcodes.php @@ -5,7 +5,7 @@ * @package LifterLMS/Classes/Shortcodes * * @since 1.0.0 - * @version 7.2.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -37,6 +37,7 @@ public function __construct() { * @since 4.0.0 Stop registering previously deprecated shortcode `[courses]` and `[lifterlms_user_statistics]`. * @since 6.0.0 Removed loading of class files that don't instantiate their class in favor of autoloading. * @since 6.4.0 Allowed `LLMS_Shortcode_User_Info` class to be filtered. + * @since [version] Added `LLMS_Shortcode_Favorites` class in shortcodes array. * * @return void */ diff --git a/templates/myaccount/dashboard.php b/templates/myaccount/dashboard.php index a889e06fe0..8cd85c0f6e 100644 --- a/templates/myaccount/dashboard.php +++ b/templates/myaccount/dashboard.php @@ -1,6 +1,6 @@ Date: Fri, 28 Jul 2023 13:34:45 +0530 Subject: [PATCH 045/522] cs and code fixes --- .changelogs/feature_favorite-2.yml | 2 +- assets/js/llms-favorites.js | 6 +- class-lifterlms.php | 24 +---- .../settings/class.llms.settings.accounts.php | 2 +- includes/class.llms.ajax.php | 2 +- includes/class.llms.frontend.assets.php | 2 +- includes/class.llms.student.dashboard.php | 2 +- .../functions/llms.functions.favorite.php | 30 +++++- includes/functions/llms.functions.person.php | 16 +-- .../llms.functions.templates.dashboard.php | 21 ++-- includes/llms.template.functions.php | 10 +- includes/llms.template.hooks.php | 2 +- includes/models/model.llms.student.php | 99 +++++++++---------- .../class.llms.shortcode.favorites.php | 2 +- templates/content-single-lesson-before.php | 2 +- templates/course/favorite.php | 30 +++++- templates/course/lesson-preview.php | 18 +++- templates/myaccount/dashboard.php | 5 +- .../unit-tests/class-llms-test-query.php | 4 +- 19 files changed, 153 insertions(+), 126 deletions(-) diff --git a/.changelogs/feature_favorite-2.yml b/.changelogs/feature_favorite-2.yml index a86c9048c8..bbaf6927ef 100644 --- a/.changelogs/feature_favorite-2.yml +++ b/.changelogs/feature_favorite-2.yml @@ -1,4 +1,4 @@ significance: minor type: dev -entry: Added filter `lifterlms_single_course_syllabus_lesson_favorite` for +entry: Added filter `llms_course_syllabus_lesson_favorite_visibility` for disabling favorites in syllabus view. diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index c694daee9f..ce503376fe 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -4,9 +4,9 @@ /** * Front End Favorite Class. * - * @type {Object} - * @since [version] - * @version [version] + * @type {Object} + * @since [version] + * @version [version] */ ( function( $ ) { diff --git a/class-lifterlms.php b/class-lifterlms.php index 6462d75cc7..c4356a60a3 100644 --- a/class-lifterlms.php +++ b/class-lifterlms.php @@ -5,7 +5,7 @@ * @package LifterLMS/Main * * @since 1.0.0 - * @version [version] + * @version 7.2.0 */ defined( 'ABSPATH' ) || exit; @@ -24,7 +24,6 @@ * Remove deprecated class files and variables. * Move includes (file loading) into the LLMS_Loader class. * @since 5.3.0 Replace singleton code with `LLMS_Trait_Singleton`. - * @since [version] Added `is_favorites_enabled` to check favorites status. */ final class LifterLMS { @@ -421,25 +420,4 @@ public function localize() { } - /** - * Filter Hook to enable the Favorite feature. - * - * @since [version] - * - * @return boolean - */ - public function is_favorites_enabled() { - - $favorite_enabled = llms_parse_bool( get_option( 'lifterlms_favorites', 'no' ) ); - - /** - * Filter to enable/disable the Favorite feature. - * - * @since [version] - * - * @param boolean $favorite_enabled True if favorites are enabled, false otherwise. - */ - return apply_filters( 'llms_favorites_enabled', $favorite_enabled ); - } - } diff --git a/includes/admin/settings/class.llms.settings.accounts.php b/includes/admin/settings/class.llms.settings.accounts.php index abfcb4a686..d3f86f3c06 100644 --- a/includes/admin/settings/class.llms.settings.accounts.php +++ b/includes/admin/settings/class.llms.settings.accounts.php @@ -188,7 +188,7 @@ public function get_settings() { 'type' => 'text', 'default' => 'my-favorites', 'sanitize' => 'slug', - 'disabled' => ! llms()->is_favorites_enabled() ? true : false, + 'disabled' => ! llms_is_favorites_enabled() ? true : false, ), array( 'title' => __( 'Notifications', 'lifterlms' ), diff --git a/includes/class.llms.ajax.php b/includes/class.llms.ajax.php index e4e21b3034..1be5de105c 100644 --- a/includes/class.llms.ajax.php +++ b/includes/class.llms.ajax.php @@ -241,7 +241,7 @@ public function favorite_object() { echo json_encode( array( - 'total_favorites' => get_total_favorites( $object_id ), + 'total_favorites' => llms_get_object_total_favorites( $object_id ), 'success' => true, ) ); diff --git a/includes/class.llms.frontend.assets.php b/includes/class.llms.frontend.assets.php index 8e08b0d1c3..b91b7b1ef3 100644 --- a/includes/class.llms.frontend.assets.php +++ b/includes/class.llms.frontend.assets.php @@ -201,7 +201,7 @@ public static function enqueue_scripts() { llms()->assets->enqueue_script( 'llms-quiz' ); } - if ( ( is_lesson() || is_course() ) && true === llms()->is_favorites_enabled() ) { + if ( ( is_lesson() || is_course() ) && true === llms_is_favorites_enabled() ) { llms()->assets->enqueue_script( 'llms-favorites' ); } diff --git a/includes/class.llms.student.dashboard.php b/includes/class.llms.student.dashboard.php index f6660f9f98..d3f5a4f597 100644 --- a/includes/class.llms.student.dashboard.php +++ b/includes/class.llms.student.dashboard.php @@ -192,7 +192,7 @@ public static function get_tabs() { ), 'view-favorites' => array( 'content' => 'lifterlms_template_student_dashboard_my_favorites', - 'endpoint' => llms()->is_favorites_enabled() ? get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ) : '', + 'endpoint' => llms_is_favorites_enabled() ? get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ) : '', 'paginate' => true, 'nav_item' => true, 'title' => __( 'My Favorites', 'lifterlms' ), diff --git a/includes/functions/llms.functions.favorite.php b/includes/functions/llms.functions.favorite.php index 87b3b7b075..e25b47bdbc 100644 --- a/includes/functions/llms.functions.favorite.php +++ b/includes/functions/llms.functions.favorite.php @@ -15,13 +15,18 @@ * * @since [version] * - * @param WP_Post|int|false $object_id Lesson post object or id. If `false` uses the global `$post` object. + * @param int $object_id WP Post ID of the Lesson. * @return int */ -function get_total_favorites( $object_id = false ) { +function llms_get_object_total_favorites( $object_id = false ) { global $wpdb; + // Getting ID from Global Post object. + if ( ! $object_id ) { + $object_id = get_the_ID(); + } + // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared $res = $wpdb->get_results( // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching $wpdb->prepare( @@ -36,3 +41,24 @@ function get_total_favorites( $object_id = false ) { return count( $res ); } + +/** + * Filter Hook to enable the Favorite feature. + * + * @since [version] + * + * @return bool True if favorites are enabled, false otherwise. + */ +function llms_is_favorites_enabled() { + + $favorite_enabled = llms_parse_bool( get_option( 'lifterlms_favorites', 'no' ) ); + + /** + * Filter to enable/disable the Favorite feature. + * + * @since [version] + * + * @param bool $favorite_enabled True if favorites are enabled, false otherwise. + */ + return apply_filters( 'llms_favorites_enabled', $favorite_enabled ); +} diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index 3d470bf550..44a8c6e01f 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -324,8 +324,8 @@ function llms_is_user_enrolled( $user_id, $product_id, $relation = 'all', $use_c * @see LLMS_Student->mark_complete() * * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param string $object_type Object type [lesson|section|course|track]. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. * @param string $trigger String describing the event that triggered marking the object as complete. * @return boolean */ @@ -342,8 +342,8 @@ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'uns * @see LLMS_Student->mark_incomplete() * * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param string $object_type Object type [lesson|section|course|track]. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. * @param string $trigger String describing the event that triggered marking the object as incomplete. * @return boolean */ @@ -360,8 +360,8 @@ function llms_mark_incomplete( $user_id, $object_id, $object_type, $trigger = 'u * @see LLMS_Student->mark_favorite() * * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param string $object_type Object type [lesson|section|course|track]. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. * @return boolean */ function llms_mark_favorite( $user_id, $object_id, $object_type ) { @@ -377,8 +377,8 @@ function llms_mark_favorite( $user_id, $object_id, $object_type ) { * @see LLMS_Student->mark_unfavorite() * * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param string $object_type Object type [lesson|section|course|track]. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. * @return boolean */ function llms_mark_unfavorite( $user_id, $object_id, $object_type ) { diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 0139690cac..5fc0edb9a6 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -153,7 +153,7 @@ function lifterlms_student_dashboard( $options = array() ) { } -if ( ! function_exists( 'lifterlms_template_my_courses_loop' ) ) { +if ( ! function_exists( 'llms_template_my_courses_loop' ) ) { /** * Get course tiles for a student's courses @@ -168,7 +168,7 @@ function lifterlms_student_dashboard( $options = array() ) { * @param bool $preview Optional. If true, outputs a short list of courses (based on dashboard_recent_courses filter). Default `false`. * @return void */ - function lifterlms_template_my_courses_loop( $student = null, $preview = false ) { + function llms_template_my_courses_loop( $student = null, $preview = false ) { $student = llms_get_student( $student ); if ( ! $student ) { @@ -288,17 +288,18 @@ function lifterlms_template_my_courses_loop( $student = null, $preview = false ) } } -if ( ! function_exists( 'lifterlms_template_my_favorites_loop' ) ) { +if ( ! function_exists( 'llms_template_my_favorites_loop' ) ) { /** * Get student's favorites. * * @since [version] * - * @param LLMS_Student $student Optional. LLMS_Student (current student if none supplied). Default `null`. + * @param LLMS_Student $student Optional. LLMS_Student (current student if none supplied). Default `null`. + * @param array $favorites Optional. Array of favorites (current student's favorites if none supplied). Default `null`. * @return void */ - function lifterlms_template_my_favorites_loop( $student = null, $favorites = null ) { + function llms_template_my_favorites_loop( $student = null, $favorites = null ) { $student = llms_get_student( $student ); if ( ! $student ) { @@ -315,8 +316,8 @@ function lifterlms_template_my_favorites_loop( $student = null, $favorites = nul // Adding Parent Course IDs in Favorites for each lesson. foreach ( $favorites as $key => $favorite ) { - $parent_course = get_post_meta( $favorite->post_id, '_llms_parent_course', true ); - $favorite->parent_course = $parent_course; + $lesson = new LLMS_Lesson( $favorite->post_id ); + $favorite->parent_course = $lesson->get( 'parent_course' ); } // Grouping Favorites by Parent Course ID. @@ -587,7 +588,7 @@ function lifterlms_template_student_dashboard_my_courses( $preview = false ) { } ob_start(); - lifterlms_template_my_courses_loop( $student, $preview ); + llms_template_my_courses_loop( $student, $preview ); llms_get_template( 'myaccount/dashboard-section.php', @@ -617,7 +618,7 @@ function lifterlms_template_student_dashboard_my_favorites( $preview = false ) { $student = llms_get_student(); - if ( ! $student || ! llms()->is_favorites_enabled() ) { + if ( ! $student || ! llms_is_favorites_enabled() ) { return; } @@ -630,7 +631,7 @@ function lifterlms_template_student_dashboard_my_favorites( $preview = false ) { } ob_start(); - lifterlms_template_my_favorites_loop( $student ); + llms_template_my_favorites_loop( $student ); llms_get_template( 'myaccount/dashboard-section.php', diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 5460244580..508e11216b 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -390,15 +390,15 @@ function lifterlms_template_single_parent_course() { * * @since [version] * - * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @param string $object_type Object type [lesson|section|course|track]. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. * @return void */ -if ( ! function_exists( 'lifterlms_template_favorite' ) ) { +if ( ! function_exists( 'llms_template_favorite' ) ) { - function lifterlms_template_favorite( $object_id = null, $object_type = 'lesson' ) { + function llms_template_favorite( $object_id = null, $object_type = 'lesson' ) { - if ( llms()->is_favorites_enabled() ) { + if ( llms_is_favorites_enabled() ) { llms_get_template( 'course/favorite.php', diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index eb8b01193c..a9c43a9490 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -48,7 +48,7 @@ * @since Unknown */ add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_parent_course', 10 ); -add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_favorite', 10 ); +add_action( 'lifterlms_single_lesson_before_summary', 'llms_template_favorite', 10 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_video', 20 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_audio', 20 ); diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 1497d12b56..b3cc840f19 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -99,7 +99,7 @@ private function add_membership_level( $membership_id ) { * * @param int $product_id WP Post ID of the course or membership * @param string $trigger String describing the reason for enrollment - * @return boolean + * @return bool */ public function enroll( $product_id, $trigger = 'unspecified' ) { @@ -268,12 +268,12 @@ public function get_courses( $args = array() ) { /** * Retrieve user's favorites based on supplied criteria. * - * @since [version] + * @since [version] * - * @param string $order_by Result set ordering field. Default "date". - * @param string $order Result set order. Default "DESC". Accepts "DESC" or "ASC". - * @param integer $limit Number of favorites to return. - * @return array + * @param string $order_by Result set ordering field. Default "date". + * @param string $order Result set order. Default "DESC". Accepts "DESC" or "ASC". + * @param int $limit Number of favorites to return. + * @return array */ public function get_favorites( $order_by = '', $order = '', $limit = '' ) { @@ -1125,7 +1125,7 @@ public function get_registration_date( $format = '' ) { * * @since 3.14.0 * - * @return boolean + * @return bool */ public function is_active() { @@ -1208,7 +1208,7 @@ public function is_instructor() { * * @param int $object_id WP Post ID of the lesson, section, course or track * @param string $trigger String describing the reason for mark completion - * @return boolean + * @return bool * @since 3.3.1 * @version 3.21.0 */ @@ -1293,13 +1293,13 @@ private function insert_incompletion_postmeta( $object_id, $trigger = 'unspecifi * @see LLMS_Student->mark_favorite() * * @param int $object_id WP User ID. - * @return boolean + * @return bool */ private function insert_favorite_postmeta( $object_id ) { $update = llms_update_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); - // Returns an array with errored keys or true on success. + // Returns boolean if postmeta update is successful. return is_array( $update ) ? false : true; } @@ -1310,13 +1310,13 @@ private function insert_favorite_postmeta( $object_id ) { * @since [version] * * @param int $object_id WP Post ID of the lesson - * @return boolean + * @return bool */ private function remove_unfavorite_postmeta( $object_id ) { $update = llms_delete_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); - // Returns an array with errored keys or true on success. + // Returns boolean if postmeta update is successful. return is_array( $update ) ? false : true; } @@ -1353,7 +1353,7 @@ private function insert_enrollment_postmeta( $product_id, $trigger = 'unspecifie * * @param int $product_id WP Post ID of the course or membership. * @param string $trigger Optional. String the reason for enrollment. Default `null` - * @return boolean Whether or not the enrollment records have been succesfully removed. + * @return bool Whether or not the enrollment records have been succesfully removed. */ private function delete_enrollment_postmeta( $product_id, $trigger = null ) { @@ -1444,12 +1444,12 @@ public function is_enrolled( $product_ids = null, $relation = 'all', $use_cache } /** - * Mark a lesson, section, course, or track complete for the given user + * Mark a lesson, section, course, or track complete for the given user. * * @param int $object_id WP Post ID of the lesson, section, course, or track * @param string $object_type object type [lesson|section|course|track] * @param string $trigger String describing the reason for marking complete - * @return boolean + * @return bool * * @see llms_mark_complete() calls this function without having to instantiate the LLMS_Student class first * @@ -1474,7 +1474,7 @@ public function mark_complete( $object_id, $object_type, $trigger = 'unspecified * @param int $object_id WP Post ID of the lesson, section, course, or track * @param string $object_type object type [lesson|section|course|track] * @param string $trigger String describing the reason for marking incomplete - * @return boolean + * @return bool * * @see llms_mark_incomplete() calls this function without having to instantiate the LLMS_Student class first * @@ -1552,7 +1552,7 @@ private function remove_membership_level( $membership_id, $status = 'expired', $ * @param string $trigger Only remove the student if the original enrollment trigger matches the submitted value. * Passing `any` will remove regardless of enrollment trigger. * @param string $new_status the value to update the new status with after removal is complete. - * @return boolean + * @return bool */ public function unenroll( $product_id, $trigger = 'any', $new_status = 'expired' ) { @@ -1656,7 +1656,7 @@ public function unenroll( $product_id, $trigger = 'any', $new_status = 'expired' * @param int $product_id WP Post ID of the course or membership. * @param string $trigger Optional. Only delete the student's enrollment if the original enrollment trigger matches the submitted value. * "any" will remove regardless of enrollment trigger. Default "any". - * @return boolean Whether or not the enrollment records have been successfully removed. + * @return bool Whether or not the enrollment records have been successfully removed. */ public function delete_enrollment( $product_id, $trigger = 'any' ) { @@ -1744,7 +1744,7 @@ public function delete_enrollment( $product_id, $trigger = 'any' ) { * @param int $object_id WP_Post ID of the object. * @param string $object_type The type of object. A lesson, section, course, or course_track. * @param string $trigger String describing the reason for the status change. - * @return boolean + * @return bool */ private function update_completion_status( $status, $object_id, $object_type, $trigger = 'unspecified' ) { @@ -1914,9 +1914,9 @@ private function update_completion_status( $status, $object_id, $object_type, $t * * @since [version] * - * @param int $object_id WP Post ID of a course or lesson or section or the term id of the track. - * @param string $object_type Object type (course, lesson, section, or track). - * @return boolean + * @param int $object_id WP Post ID of a lesson. + * @param string $object_type Type, 'Lesson'. + * @return bool */ public function is_favorite( $object_id, $object_type = 'lesson' ) { @@ -1935,29 +1935,29 @@ public function is_favorite( $object_id, $object_type = 'lesson' ) { /** * Filter object favorite boolean value prior to returning. * - * The dynamic portion of this filter, `{$object_type}`, refers to the Lesson, Course or Instructor. + * The dynamic portion of this filter, `{$object_type}`, refers to the Lesson. * * @since [version] * - * @param array|false $ret Array of favorite data or `false` if no favorite is found. - * @param int $object_id Object ID (Lesson, Course or Instructor). - * @param string $object_type Object description string (Lesson, Course or Instructor). - * @param LLMS_Student $instance The Student Instance + * @param array|false $ret Array of favorite data or `false` if no favorite is found. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. + * @param LLMS_Student $instance The Student Instance */ return apply_filters( 'llms_is_' . $object_type . '_favorite', $ret, $object_id, $object_type, $this ); } /** - * Mark a lesson, section, course, or track favorite for the given user. + * Mark a lesson favorite for the given user. * * @since [version] * * @see llms_mark_favorite() calls this function without having to instantiate the LLMS_Student class first. * - * @param int $object_id WP Post ID of the lesson, section, course, or track. - * @param string $object_type object type [lesson|section|course|track]. - * @return boolean + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. + * @return bool */ public function mark_favorite( $object_id, $object_type ) { @@ -1971,15 +1971,15 @@ public function mark_favorite( $object_id, $object_type ) { } /** - * Mark a lesson, section, course, or track unfavorite for the given user. + * Mark a lesson unfavorite for the given user. * - * @since [version] + * @since [version] * - * @see llms_mark_unfavorite() calls this function without having to instantiate the LLMS_Student class first. + * @see llms_mark_unfavorite() calls this function without having to instantiate the LLMS_Student class first. * - * @param int $object_id WP Post ID of the lesson, section, course, or track. - * @param string $object_type object type [lesson|section|course|track]. - * @return boolean + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. + * @return bool */ public function mark_unfavorite( $object_id, $object_type ) { @@ -1995,16 +1995,16 @@ public function mark_unfavorite( $object_id, $object_type ) { /** * Triggers actions for favorite/unfavorite. * - * Update the favorite status of a track, course, section, or lesson for the current student + * Update the favorite status of a lesson for the current student. * Inserts / updates necessary user postmeta data. * * @since [version] Use filterable functions to determine if the object can be marked favorite. * * @param string $status New status to update to, either "favorite" or "unfavorite". - * @param int $object_id WP_Post ID of the object. - * @param string $object_type The type of object. A lesson, section, course, or course_track. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. * @param string $trigger String describing the reason for the status change. - * @return boolean + * @return bool */ private function update_favorite_status( $status, $object_id, $object_type, $trigger = 'unspecified' ) { @@ -2019,21 +2019,12 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * @since [version] * * @param int $student_id WP_User ID of the student. - * @param int $object_id WP_Post ID of the object. - * @param string $object_type The type of object. A lesson, section, course, or course_track. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. * @param string $trigger String describing the reason for the status change. */ do_action( "before_llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); - // Retrieve an instance of the object we're acting on. - if ( in_array( $object_type, llms_get_completable_post_types(), true ) ) { - $object = llms_get_post( $object_id ); - } elseif ( in_array( $object_type, llms_get_completable_taxonomies(), true ) ) { - $object = get_term( $object_id, $object_type ); - } else { - return false; - } - // Insert / Remove meta data. if ( 'favorite' === $status ) { $this->insert_favorite_postmeta( $object_id, $trigger ); @@ -2050,8 +2041,8 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * @since [version] * * @param int $student_id WP_User ID of the student. - * @param int $object_id WP_Post ID of the object. - * @param string $object_type The type of object. A lesson, section, course, or course_track. + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. * @param string $trigger String describing the reason for the status change. */ do_action( "llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); diff --git a/includes/shortcodes/class.llms.shortcode.favorites.php b/includes/shortcodes/class.llms.shortcode.favorites.php index 9463e6a91b..11399734a4 100644 --- a/includes/shortcodes/class.llms.shortcode.favorites.php +++ b/includes/shortcodes/class.llms.shortcode.favorites.php @@ -91,7 +91,7 @@ protected function get_output() { $favorites = $this->get_favorites(); - lifterlms_template_my_favorites_loop( get_current_user_id(), $favorites ); + llms_template_my_favorites_loop( get_current_user_id(), $favorites ); } return ob_get_clean(); diff --git a/templates/content-single-lesson-before.php b/templates/content-single-lesson-before.php index 9610309e7a..007fabe67c 100644 --- a/templates/content-single-lesson-before.php +++ b/templates/content-single-lesson-before.php @@ -12,7 +12,7 @@ /** * @hooked - lifterlms_template_single_parent_course - 10 - * @hooked - lifterlms_template_favorite - 10 + * @hooked - llms_template_favorite - 10 * @hooked - lifterlms_template_single_lesson_video - 20 * @hooked - lifterlms_template_single_lesson_audio - 20 */ diff --git a/templates/course/favorite.php b/templates/course/favorite.php index da6fe95d91..2d6b6d4b83 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -8,8 +8,8 @@ * * @since [version] * - * @var int $object_id WP Post ID of the Lesson, Section, Track, or Course. - * @var string $object_type Object type [lesson|section|course|track]. + * @var int $object_id WP Post ID of the Lesson. + * @var string $object_type Type, 'Lesson'. */ defined( 'ABSPATH' ) || exit; @@ -17,12 +17,22 @@ $lesson = new LLMS_Lesson( ( null === $object_id || '' === $object_id ) ? $post->ID : $object_id ); $student = llms_get_student( get_current_user_id() ); -$total_favorites = get_total_favorites( $lesson->get( 'id' ) ); +$total_favorites = llms_get_object_total_favorites( $lesson->get( 'id' ) ); ?>
- + @@ -46,6 +56,16 @@ - +
diff --git a/templates/course/lesson-preview.php b/templates/course/lesson-preview.php index ef3fe8dd4b..a3fa37a396 100644 --- a/templates/course/lesson-preview.php +++ b/templates/course/lesson-preview.php @@ -9,7 +9,7 @@ * @since 3.19.2 Unknown. * @since 4.4.0 Use the passed `$order` param if available, in favor of retrieving the lesson's order post meta. * @since 5.7.0 Replaced the call to the deprecated `LLMS_Lesson::get_order()` method with `LLMS_Lesson::get( 'order' )`. - * @since [version] Added Favorites function `lifterlms_template_favorite()`. + * @since [version] Added Favorites function `llms_template_favorite()`. * @version [version] * * @var LLMS_Lesson $lesson The lesson object. @@ -47,9 +47,19 @@
get( 'id' ) ); ?>
- - get( 'id' ) ); ?> - + get( 'id' ) ); + endif; + ?> get( 'id' ) ) ) : ?>
get( 'id' ) ); ?>
diff --git a/templates/myaccount/dashboard.php b/templates/myaccount/dashboard.php index 8cd85c0f6e..9674094234 100644 --- a/templates/myaccount/dashboard.php +++ b/templates/myaccount/dashboard.php @@ -4,8 +4,9 @@ * * @package LifterLMS/Templates * - * @since 1.0.0 - * @version [version] + * @since 1.0.0 + * @since [version] Hooked my_favorites function. + * @version [version] */ defined( 'ABSPATH' ) || exit; diff --git a/tests/phpunit/unit-tests/class-llms-test-query.php b/tests/phpunit/unit-tests/class-llms-test-query.php index 09463d96e1..a592986fcb 100644 --- a/tests/phpunit/unit-tests/class-llms-test-query.php +++ b/tests/phpunit/unit-tests/class-llms-test-query.php @@ -81,7 +81,7 @@ public function test_add_endpoints() { 'view-memberships' => 'lifterlms_myaccount_memberships_endpoint', 'view-achievements' => 'lifterlms_myaccount_achievements_endpoint', 'view-certificates' => 'lifterlms_myaccount_certificates_endpoint', - 'view-favorites' => 'lifterlms_myaccount_favorites_endpoint', + 'view-favorites' => 'lifterlms_myaccount_favorites_endpoint', 'notifications' => 'lifterlms_myaccount_notifications_endpoint', 'edit-account' => 'lifterlms_myaccount_edit_account_endpoint', 'redeem-voucher' => 'lifterlms_myaccount_redeem_vouchers_endpoint', @@ -94,7 +94,7 @@ public function test_add_endpoints() { 'view-memberships' => 'ਵੇਖੋ-ਸਦੱਸਤਾ', // Punjabi. 'view-achievements' => 'nailiyyətlər', // Azerbaijani. 'view-certificates' => 'ເບິ່ງໃບຢັ້ງຢືນ', // Lao. - 'view-favorites' => '즐겨찾기', // Korean. + 'view-favorites' => '즐겨찾기', // Korean. 'notifications' => '通知', // Chinese (Simplified). 'edit-account' => 'חשבון-עריכה', // Hebrew. 'redeem-voucher' => 'چھڑانا', // Urdu. From 63fada045d71d8e7587ec598bdc8037881957da7 Mon Sep 17 00:00:00 2001 From: Akash <18614782+actuallyakash@users.noreply.github.com> Date: Fri, 28 Jul 2023 13:40:20 +0530 Subject: [PATCH 046/522] Apply suggestions from code review Co-authored-by: Rocco Aliberti --- assets/js/llms-favorites.js | 16 ++++++++-------- .../llms.functions.templates.dashboard.php | 6 +++--- .../class.llms.shortcode.favorites.php | 2 +- templates/course/favorite.php | 2 +- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index ce503376fe..9018ed80a1 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -15,16 +15,16 @@ /** * Main Favorite Container Element. * - * @type obj + * @type {Object} */ $container: null, /** * Bind DOM events. * - * @return void - * @since [version] - * @version [version] + * @since [version] + * + * @return {Void} */ bind: function() { @@ -45,10 +45,10 @@ /** * Favorite / Unfavorite an object. * - * @param obj $btn jQuery object for the "Favorite / Unfavorite" button. - * @return void - * @since [version] - * @version [version] + * @since [version] + * + * @param {Object} $btn jQuery object for the "Favorite / Unfavorite" button. + * @return {Void} */ favorite: function( $btn ) { diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 5fc0edb9a6..65cf85e4ad 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -310,7 +310,7 @@ function llms_template_my_favorites_loop( $student = null, $favorites = null ) { if ( ! $favorites ) { - printf( '

%s

', __( 'No favorites found.', 'lifterlms' ) ); + printf( '

%s

', esc_html__( 'No favorites found.', 'lifterlms' ) ); } else { @@ -626,7 +626,7 @@ function lifterlms_template_student_dashboard_my_favorites( $preview = false ) { if ( $preview && LLMS_Student_Dashboard::is_endpoint_enabled( 'view-favorites' ) ) { $more = array( 'url' => llms_get_endpoint_url( 'view-favorites', '', llms_get_page_url( 'myaccount' ) ), - 'text' => __( 'View All My Favorites', 'lifterlms' ), + 'text' => esc_html__( 'View All My Favorites', 'lifterlms' ), ); } @@ -638,7 +638,7 @@ function lifterlms_template_student_dashboard_my_favorites( $preview = false ) { array( 'action' => 'my_favorites', 'slug' => 'llms-my-favorites', - 'title' => $preview ? __( 'My Favorites', 'lifterlms' ) : '', + 'title' => $preview ? esc_html__( 'My Favorites', 'lifterlms' ) : '', 'content' => ob_get_clean(), 'more' => $more, ) diff --git a/includes/shortcodes/class.llms.shortcode.favorites.php b/includes/shortcodes/class.llms.shortcode.favorites.php index 11399734a4..f382cc8456 100644 --- a/includes/shortcodes/class.llms.shortcode.favorites.php +++ b/includes/shortcodes/class.llms.shortcode.favorites.php @@ -82,7 +82,7 @@ protected function get_output() { if ( ! llms_get_student() ) { printf( - __( 'You must be logged in to view this information. Click %1$shere%2$s to login.', 'lifterlms' ), + esc_html__( 'You must be logged in to view this information. Click %1$shere%2$s to login.', 'lifterlms' ), '', '' ); diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 2d6b6d4b83..2ca3ade996 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -15,7 +15,7 @@ global $post; -$lesson = new LLMS_Lesson( ( null === $object_id || '' === $object_id ) ? $post->ID : $object_id ); +$lesson = new LLMS_Lesson( empty( $object_id ) ? $post->ID : $object_id ); $student = llms_get_student( get_current_user_id() ); $total_favorites = llms_get_object_total_favorites( $lesson->get( 'id' ) ); ?> From 0ba96ba2ca07403d1869bd38b5fe2821a1e877ed Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Fri, 28 Jul 2023 13:46:28 +0530 Subject: [PATCH 047/522] minor fixes --- assets/js/llms-favorites.js | 3 +-- includes/class.llms.student.dashboard.php | 2 +- includes/functions/llms.functions.templates.dashboard.php | 4 ++-- includes/llms.template.hooks.php | 2 +- templates/myaccount/dashboard.php | 2 +- 5 files changed, 6 insertions(+), 7 deletions(-) diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index 9018ed80a1..3b200c3b10 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -1,4 +1,4 @@ -;/* global LLMS, $ */ +/* global LLMS, $ */ /* jshint strict: true */ /** @@ -85,7 +85,6 @@ // Updating count. self.$container.find( '.llms-favorites-count' ).text( r.total_favorites ); - } diff --git a/includes/class.llms.student.dashboard.php b/includes/class.llms.student.dashboard.php index d3f5a4f597..2a135ed16b 100644 --- a/includes/class.llms.student.dashboard.php +++ b/includes/class.llms.student.dashboard.php @@ -191,7 +191,7 @@ public static function get_tabs() { 'title' => __( 'My Certificates', 'lifterlms' ), ), 'view-favorites' => array( - 'content' => 'lifterlms_template_student_dashboard_my_favorites', + 'content' => 'llms_template_student_dashboard_my_favorites', 'endpoint' => llms_is_favorites_enabled() ? get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ) : '', 'paginate' => true, 'nav_item' => true, diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 65cf85e4ad..9990e7c794 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -604,7 +604,7 @@ function lifterlms_template_student_dashboard_my_courses( $preview = false ) { } } -if ( ! function_exists( 'lifterlms_template_student_dashboard_my_favorites' ) ) { +if ( ! function_exists( 'llms_template_student_dashboard_my_favorites' ) ) { /** * Template for My Favorites section on dashboard index. @@ -614,7 +614,7 @@ function lifterlms_template_student_dashboard_my_courses( $preview = false ) { * @param bool $preview Optional. If true, outputs a short list of favorites. Default `false`. * @return void */ - function lifterlms_template_student_dashboard_my_favorites( $preview = false ) { + function llms_template_student_dashboard_my_favorites( $preview = false ) { $student = llms_get_student(); diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index a9c43a9490..fd5af4c2bf 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -169,7 +169,7 @@ add_action( 'llms_achievement_content', 'llms_the_achievement', 10 ); add_action( 'llms_certificate_preview', 'llms_the_certificate_preview', 10 ); add_action( 'lifterlms_student_dashboard_index', 'lifterlms_template_student_dashboard_my_memberships', 40 ); -add_action( 'lifterlms_student_dashboard_index', 'lifterlms_template_student_dashboard_my_favorites', 50 ); +add_action( 'lifterlms_student_dashboard_index', 'llms_template_student_dashboard_my_favorites', 50 ); add_action( 'llms_my_grades_course_table', 'lifterlms_template_student_dashboard_my_grades_table', 10, 2 ); diff --git a/templates/myaccount/dashboard.php b/templates/myaccount/dashboard.php index 9674094234..0a282174ce 100644 --- a/templates/myaccount/dashboard.php +++ b/templates/myaccount/dashboard.php @@ -27,7 +27,7 @@ * @hooked lifterlms_template_student_dashboard_my_achievements - 20 * @hooked lifterlms_template_student_dashboard_my_certificates - 30 * @hooked lifterlms_template_student_dashboard_my_memberships - 40 - * @hooked lifterlms_template_student_dashboard_my_favorites - 50 + * @hooked llms_template_student_dashboard_my_favorites - 50 */ do_action( 'lifterlms_student_dashboard_index', true ); From f596c5dda80c02c1f29f1f187f76555741ea2f25 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Fri, 28 Jul 2023 14:02:24 +0530 Subject: [PATCH 048/522] minor cs fixes --- includes/models/model.llms.student.php | 2 +- templates/course/favorite.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index b3cc840f19..0ea7890fa4 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1309,7 +1309,7 @@ private function insert_favorite_postmeta( $object_id ) { * * @since [version] * - * @param int $object_id WP Post ID of the lesson + * @param int $object_id WP Post ID of the lesson * @return bool */ private function remove_unfavorite_postmeta( $object_id ) { diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 2ca3ade996..7bd88b96f1 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -15,7 +15,7 @@ global $post; -$lesson = new LLMS_Lesson( empty( $object_id ) ? $post->ID : $object_id ); +$lesson = new LLMS_Lesson( empty( $object_id ) ? $post->ID : $object_id ); $student = llms_get_student( get_current_user_id() ); $total_favorites = llms_get_object_total_favorites( $lesson->get( 'id' ) ); ?> From ef2b482ae886c2f2f00166e9fd0cbfa77ba001d8 Mon Sep 17 00:00:00 2001 From: Akash <18614782+actuallyakash@users.noreply.github.com> Date: Fri, 28 Jul 2023 18:06:09 +0530 Subject: [PATCH 049/522] Apply suggestions from code review Co-authored-by: Rocco Aliberti --- assets/js/llms-favorites.js | 9 +++++---- includes/class.llms.query.user.postmeta.php | 4 +--- includes/functions/llms.functions.favorite.php | 2 +- includes/models/model.llms.student.php | 4 ++-- templates/course/favorite.php | 5 ++--- 5 files changed, 11 insertions(+), 13 deletions(-) diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index 3b200c3b10..548292eb2e 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -4,8 +4,9 @@ /** * Front End Favorite Class. * - * @type {Object} - * @since [version] + * @type {Object} + * + * @since [version] * @version [version] */ ( function( $ ) { @@ -30,14 +31,14 @@ var self = this; - // Favorite clicked + // Favorite clicked. $( '.llms-favorite-wrapper' ).on( 'click', function( e ) { e.preventDefault(); let $btn = $( this ).find( '.llms-heart-btn' ); self.favorite( $btn ); } ); - // Adding class in Favorite's parent + // Adding class in Favorite's parent. $( '.llms-favorite-wrapper' ).parent().addClass( 'llms-has-favorite' ); }, diff --git a/includes/class.llms.query.user.postmeta.php b/includes/class.llms.query.user.postmeta.php index b4cc0759bf..84acc8c2ca 100644 --- a/includes/class.llms.query.user.postmeta.php +++ b/includes/class.llms.query.user.postmeta.php @@ -14,7 +14,6 @@ * LifterLMS User Postmeta Query * * @since 3.15.0 - * @version [version] */ class LLMS_Query_User_Postmeta extends LLMS_Database_Query { @@ -87,8 +86,7 @@ public function get_metas() { * * @return void * @since 3.15.0 - * @since [version] Added 'Favorites' event. - * @version [version] + * @since [version] Added 'Favorites' event. */ protected function parse_args() { diff --git a/includes/functions/llms.functions.favorite.php b/includes/functions/llms.functions.favorite.php index e25b47bdbc..19c965f94c 100644 --- a/includes/functions/llms.functions.favorite.php +++ b/includes/functions/llms.functions.favorite.php @@ -15,7 +15,7 @@ * * @since [version] * - * @param int $object_id WP Post ID of the Lesson. + * @param bool|int $object_id WP Post ID of the Lesson. If not supplied it will default to the current post ID. * @return int */ function llms_get_object_total_favorites( $object_id = false ) { diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 0ea7890fa4..1e649de968 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -273,7 +273,7 @@ public function get_courses( $args = array() ) { * @param string $order_by Result set ordering field. Default "date". * @param string $order Result set order. Default "DESC". Accepts "DESC" or "ASC". * @param int $limit Number of favorites to return. - * @return array + * @return bool|array */ public function get_favorites( $order_by = '', $order = '', $limit = '' ) { @@ -1309,7 +1309,7 @@ private function insert_favorite_postmeta( $object_id ) { * * @since [version] * - * @param int $object_id WP Post ID of the lesson + * @param int $object_id WP Post ID of the lesson. * @return bool */ private function remove_unfavorite_postmeta( $object_id ) { diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 7bd88b96f1..4d15eb7cfa 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -1,5 +1,4 @@ Date: Fri, 28 Jul 2023 18:15:33 +0530 Subject: [PATCH 050/522] minor fixes --- includes/class.llms.ajax.php | 1 - includes/functions/llms.functions.person.php | 10 +++++----- .../llms.functions.templates.dashboard.php | 6 +++--- includes/llms.template.functions.php | 18 +++++++++--------- includes/models/model.llms.student.php | 2 +- 5 files changed, 18 insertions(+), 19 deletions(-) diff --git a/includes/class.llms.ajax.php b/includes/class.llms.ajax.php index 1be5de105c..692c6049a3 100644 --- a/includes/class.llms.ajax.php +++ b/includes/class.llms.ajax.php @@ -20,7 +20,6 @@ * - `LLMS_AJAX::check_voucher_duplicate()` method. * - `LLMS_AJAX::get_ajax_data()` method. * - `LLMS_AJAX::register_script()` method. - * @since [version] Added method `favorite_object` to Add Favorite / Unfavorite Postmeta for an object. */ class LLMS_AJAX { diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index 44a8c6e01f..dc68e2f3c5 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -324,9 +324,9 @@ function llms_is_user_enrolled( $user_id, $product_id, $relation = 'all', $use_c * @see LLMS_Student->mark_complete() * * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. - * @param string $trigger String describing the event that triggered marking the object as complete. + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param string $object_type Object type [lesson|section|course|track]. + * @param string $trigger String describing the event that triggered marking the object as incomplete. * @return boolean */ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'unspecified' ) { @@ -342,8 +342,8 @@ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'uns * @see LLMS_Student->mark_incomplete() * * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. + * @param string $object_type Object type [lesson|section|course|track]. * @param string $trigger String describing the event that triggered marking the object as incomplete. * @return boolean */ diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 9990e7c794..3c6301ae2d 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -153,7 +153,7 @@ function lifterlms_student_dashboard( $options = array() ) { } -if ( ! function_exists( 'llms_template_my_courses_loop' ) ) { +if ( ! function_exists( 'lifterlms_template_my_courses_loop' ) ) { /** * Get course tiles for a student's courses @@ -168,7 +168,7 @@ function lifterlms_student_dashboard( $options = array() ) { * @param bool $preview Optional. If true, outputs a short list of courses (based on dashboard_recent_courses filter). Default `false`. * @return void */ - function llms_template_my_courses_loop( $student = null, $preview = false ) { + function lifterlms_template_my_courses_loop( $student = null, $preview = false ) { $student = llms_get_student( $student ); if ( ! $student ) { @@ -588,7 +588,7 @@ function lifterlms_template_student_dashboard_my_courses( $preview = false ) { } ob_start(); - llms_template_my_courses_loop( $student, $preview ); + lifterlms_template_my_courses_loop( $student, $preview ); llms_get_template( 'myaccount/dashboard-section.php', diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 508e11216b..8e759e158f 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -385,17 +385,17 @@ function lifterlms_template_single_parent_course() { } } -/** - * Favorite Lesson Template Include. - * - * @since [version] - * - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. - * @return void - */ if ( ! function_exists( 'llms_template_favorite' ) ) { + /** + * Favorite Lesson Template Include. + * + * @since [version] + * + * @param int $object_id WP Post ID of the Lesson. + * @param string $object_type Type, 'Lesson'. + * @return void + */ function llms_template_favorite( $object_id = null, $object_type = 'lesson' ) { if ( llms_is_favorites_enabled() ) { diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 1e649de968..95eb20de29 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1292,7 +1292,7 @@ private function insert_incompletion_postmeta( $object_id, $trigger = 'unspecifi * * @see LLMS_Student->mark_favorite() * - * @param int $object_id WP User ID. + * @param int $object_id WP Post ID of the lesson. * @return bool */ private function insert_favorite_postmeta( $object_id ) { From ceffca68c75981060e43cca72baeb9c2f1d7f9a6 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Fri, 28 Jul 2023 20:51:04 +0530 Subject: [PATCH 051/522] fix failing tests --- includes/class.llms.student.dashboard.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class.llms.student.dashboard.php b/includes/class.llms.student.dashboard.php index 2a135ed16b..395be15b5a 100644 --- a/includes/class.llms.student.dashboard.php +++ b/includes/class.llms.student.dashboard.php @@ -192,7 +192,7 @@ public static function get_tabs() { ), 'view-favorites' => array( 'content' => 'llms_template_student_dashboard_my_favorites', - 'endpoint' => llms_is_favorites_enabled() ? get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ) : '', + 'endpoint' => get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ), 'paginate' => true, 'nav_item' => true, 'title' => __( 'My Favorites', 'lifterlms' ), From e282976a3ee9f043493f1d3fe6d26a61045ca5b2 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 31 Jul 2023 12:33:57 +0530 Subject: [PATCH 052/522] updated docblock comments --- includes/functions/llms.functions.person.php | 8 ++--- includes/llms.template.functions.php | 4 +-- includes/models/model.llms.student.php | 32 ++++++++++---------- templates/course/favorite.php | 2 +- 4 files changed, 23 insertions(+), 23 deletions(-) diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index dc68e2f3c5..4ddfa85c00 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -360,8 +360,8 @@ function llms_mark_incomplete( $user_id, $object_id, $object_type, $trigger = 'u * @see LLMS_Student->mark_favorite() * * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @return boolean */ function llms_mark_favorite( $user_id, $object_id, $object_type ) { @@ -377,8 +377,8 @@ function llms_mark_favorite( $user_id, $object_id, $object_type ) { * @see LLMS_Student->mark_unfavorite() * * @param int $user_id WP User ID. - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @return boolean */ function llms_mark_unfavorite( $user_id, $object_id, $object_type ) { diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 8e759e158f..f85b4c12f5 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -392,8 +392,8 @@ function lifterlms_template_single_parent_course() { * * @since [version] * - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @return void */ function llms_template_favorite( $object_id = null, $object_type = 'lesson' ) { diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index 95eb20de29..edc639d779 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1292,7 +1292,7 @@ private function insert_incompletion_postmeta( $object_id, $trigger = 'unspecifi * * @see LLMS_Student->mark_favorite() * - * @param int $object_id WP Post ID of the lesson. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. * @return bool */ private function insert_favorite_postmeta( $object_id ) { @@ -1309,7 +1309,7 @@ private function insert_favorite_postmeta( $object_id ) { * * @since [version] * - * @param int $object_id WP Post ID of the lesson. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. * @return bool */ private function remove_unfavorite_postmeta( $object_id ) { @@ -1914,8 +1914,8 @@ private function update_completion_status( $status, $object_id, $object_type, $t * * @since [version] * - * @param int $object_id WP Post ID of a lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @return bool */ public function is_favorite( $object_id, $object_type = 'lesson' ) { @@ -1940,8 +1940,8 @@ public function is_favorite( $object_id, $object_type = 'lesson' ) { * @since [version] * * @param array|false $ret Array of favorite data or `false` if no favorite is found. - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @param LLMS_Student $instance The Student Instance */ return apply_filters( 'llms_is_' . $object_type . '_favorite', $ret, $object_id, $object_type, $this ); @@ -1955,8 +1955,8 @@ public function is_favorite( $object_id, $object_type = 'lesson' ) { * * @see llms_mark_favorite() calls this function without having to instantiate the LLMS_Student class first. * - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @return bool */ public function mark_favorite( $object_id, $object_type ) { @@ -1977,8 +1977,8 @@ public function mark_favorite( $object_id, $object_type ) { * * @see llms_mark_unfavorite() calls this function without having to instantiate the LLMS_Student class first. * - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @return bool */ public function mark_unfavorite( $object_id, $object_type ) { @@ -2001,8 +2001,8 @@ public function mark_unfavorite( $object_id, $object_type ) { * @since [version] Use filterable functions to determine if the object can be marked favorite. * * @param string $status New status to update to, either "favorite" or "unfavorite". - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @param string $trigger String describing the reason for the status change. * @return bool */ @@ -2019,8 +2019,8 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * @since [version] * * @param int $student_id WP_User ID of the student. - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @param string $trigger String describing the reason for the status change. */ do_action( "before_llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); @@ -2041,8 +2041,8 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * @since [version] * * @param int $student_id WP_User ID of the student. - * @param int $object_id WP Post ID of the Lesson. - * @param string $object_type Type, 'Lesson'. + * @param int $object_id WP Post ID of the object to mark/unmark as favorite. + * @param string $object_type The object type, currently only 'lesson'. * @param string $trigger String describing the reason for the status change. */ do_action( "llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 4d15eb7cfa..176bca85db 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -8,7 +8,7 @@ * @since [version] * * @param int $object_id WP Post ID of the object to mark/unmark as favorite. - * @param string $object_type The object type. Currently only the 'lesson' type is possible. + * @param string $object_type The object type, currently only 'lesson'. */ defined( 'ABSPATH' ) || exit; From 65238b5d42495e337a5d921f595adf39d6299549 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 31 Jul 2023 14:07:26 +0530 Subject: [PATCH 053/522] removed $trigger --- includes/models/model.llms.student.php | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index edc639d779..da0557287e 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -1312,7 +1312,7 @@ private function insert_favorite_postmeta( $object_id ) { * @param int $object_id WP Post ID of the object to mark/unmark as favorite. * @return bool */ - private function remove_unfavorite_postmeta( $object_id ) { + private function remove_favorite_postmeta( $object_id ) { $update = llms_delete_user_postmeta( $this->get_id(), $object_id, '_favorite', true ); @@ -2003,10 +2003,9 @@ public function mark_unfavorite( $object_id, $object_type ) { * @param string $status New status to update to, either "favorite" or "unfavorite". * @param int $object_id WP Post ID of the object to mark/unmark as favorite. * @param string $object_type The object type, currently only 'lesson'. - * @param string $trigger String describing the reason for the status change. * @return bool */ - private function update_favorite_status( $status, $object_id, $object_type, $trigger = 'unspecified' ) { + private function update_favorite_status( $status, $object_id, $object_type ) { $student_id = $this->get_id(); @@ -2021,15 +2020,14 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * @param int $student_id WP_User ID of the student. * @param int $object_id WP Post ID of the object to mark/unmark as favorite. * @param string $object_type The object type, currently only 'lesson'. - * @param string $trigger String describing the reason for the status change. */ - do_action( "before_llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); + do_action( "before_llms_mark_{$status}", $student_id, $object_id, $object_type ); // Insert / Remove meta data. if ( 'favorite' === $status ) { - $this->insert_favorite_postmeta( $object_id, $trigger ); + $this->insert_favorite_postmeta( $object_id ); } elseif ( 'unfavorite' === $status ) { - $this->remove_unfavorite_postmeta( $object_id, $trigger ); + $this->remove_favorite_postmeta( $object_id ); } /** @@ -2043,9 +2041,8 @@ private function update_favorite_status( $status, $object_id, $object_type, $tri * @param int $student_id WP_User ID of the student. * @param int $object_id WP Post ID of the object to mark/unmark as favorite. * @param string $object_type The object type, currently only 'lesson'. - * @param string $trigger String describing the reason for the status change. */ - do_action( "llms_mark_{$status}", $student_id, $object_id, $object_type, $trigger ); + do_action( "llms_mark_{$status}", $student_id, $object_id, $object_type ); /** * Hook that fires when a student's favorite status is updated for a specific object type. From 560dd80d64e5ad6380a4b975ec36935b9a638e34 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 31 Jul 2023 16:40:32 +0530 Subject: [PATCH 054/522] updated heart color and favorites shortcode design --- assets/scss/frontend/_main.scss | 2 +- .../llms.functions.templates.dashboard.php | 23 ++++++++----------- 2 files changed, 11 insertions(+), 14 deletions(-) diff --git a/assets/scss/frontend/_main.scss b/assets/scss/frontend/_main.scss index 804b905812..c956ae043c 100644 --- a/assets/scss/frontend/_main.scss +++ b/assets/scss/frontend/_main.scss @@ -492,7 +492,7 @@ svg .llms-animated-circle { cursor: pointer; .fa-heart { - color: #FF2E2B; + color: #EF476F; } } diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 3c6301ae2d..b6cb750e7e 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -330,37 +330,34 @@ function ( $carry, $item ) { array() ); + echo '
'; + // Printing Favorite Lessons under each Parent Course. foreach ( $favorites as $course => $lessons ) { // Get Course Name. - $lesson = new LLMS_Lesson( $course ); + $course = new LLMS_Course( $course ); - llms_get_template( - 'course/lesson-preview.php', - array( - 'lesson' => $lesson, - ) - ); + echo '

'; + echo $course->get( 'title' ); + echo '

'; - echo '
    '; foreach ( $lessons as $lesson ) { $lesson = new LLMS_Lesson( $lesson->post_id ); - echo '
  • '; + llms_get_template( 'course/lesson-preview.php', array( 'lesson' => $lesson, ) ); - echo '
  • '; - } - echo '
'; + } } - } + echo '
'; + } } } From c6c8a1024b879859d6b6ca9f43653a248a68cb92 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Mon, 31 Jul 2023 19:19:07 +0530 Subject: [PATCH 055/522] fixed typo due to copy/paste --- includes/functions/llms.functions.person.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index 4ddfa85c00..faa776281b 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -326,7 +326,7 @@ function llms_is_user_enrolled( $user_id, $product_id, $relation = 'all', $use_c * @param int $user_id WP User ID. * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. * @param string $object_type Object type [lesson|section|course|track]. - * @param string $trigger String describing the event that triggered marking the object as incomplete. + * @param string $trigger String describing the event that triggered marking the object as complete. * @return boolean */ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'unspecified' ) { From 35ca2364fb1ab114e39dc5b657aa59f9831888f3 Mon Sep 17 00:00:00 2001 From: actuallyakash Date: Tue, 1 Aug 2023 12:39:27 +0530 Subject: [PATCH 056/522] show favorites endpoint only when enabled --- includes/class.llms.student.dashboard.php | 166 ++++++++++++---------- 1 file changed, 88 insertions(+), 78 deletions(-) diff --git a/includes/class.llms.student.dashboard.php b/includes/class.llms.student.dashboard.php index 395be15b5a..ebc8ae9ab5 100644 --- a/includes/class.llms.student.dashboard.php +++ b/includes/class.llms.student.dashboard.php @@ -146,89 +146,99 @@ public static function get_current_tab( $return = 'data' ) { */ public static function get_tabs() { - return apply_filters( - 'llms_get_student_dashboard_tabs', - array( - 'dashboard' => array( - 'content' => 'lifterlms_template_student_dashboard_home', - 'endpoint' => false, - 'nav_item' => true, - 'title' => __( 'Dashboard', 'lifterlms' ), - 'url' => llms_get_page_url( 'myaccount' ), - ), - 'view-courses' => array( - 'content' => 'lifterlms_template_student_dashboard_my_courses', - 'endpoint' => get_option( 'lifterlms_myaccount_courses_endpoint', 'view-courses' ), - 'paginate' => true, - 'nav_item' => true, - 'title' => __( 'My Courses', 'lifterlms' ), - ), - 'my-grades' => array( - 'content' => 'lifterlms_template_student_dashboard_my_grades', - 'endpoint' => get_option( 'lifterlms_myaccount_grades_endpoint', 'my-grades' ), - 'paginate' => true, - 'nav_item' => true, - 'title' => __( 'My Grades', 'lifterlms' ), - ), - 'view-memberships' => array( - 'content' => 'lifterlms_template_student_dashboard_my_memberships', - 'endpoint' => get_option( 'lifterlms_myaccount_memberships_endpoint', 'view-memberships' ), - 'nav_item' => true, - 'title' => __( 'My Memberships', 'lifterlms' ), - ), - 'view-achievements' => array( - 'content' => 'lifterlms_template_student_dashboard_my_achievements', - 'endpoint' => get_option( 'lifterlms_myaccount_achievements_endpoint', 'view-achievements' ), - 'paginate' => true, - 'nav_item' => true, - 'title' => __( 'My Achievements', 'lifterlms' ), - ), - 'view-certificates' => array( - 'content' => 'lifterlms_template_student_dashboard_my_certificates', - 'endpoint' => get_option( 'lifterlms_myaccount_certificates_endpoint', 'view-certificates' ), - 'paginate' => true, - 'nav_item' => true, - 'title' => __( 'My Certificates', 'lifterlms' ), - ), - 'view-favorites' => array( + $tabs = array( + 'dashboard' => array( + 'content' => 'lifterlms_template_student_dashboard_home', + 'endpoint' => false, + 'nav_item' => true, + 'title' => __( 'Dashboard', 'lifterlms' ), + 'url' => llms_get_page_url( 'myaccount' ), + ), + 'view-courses' => array( + 'content' => 'lifterlms_template_student_dashboard_my_courses', + 'endpoint' => get_option( 'lifterlms_myaccount_courses_endpoint', 'view-courses' ), + 'paginate' => true, + 'nav_item' => true, + 'title' => __( 'My Courses', 'lifterlms' ), + ), + 'my-grades' => array( + 'content' => 'lifterlms_template_student_dashboard_my_grades', + 'endpoint' => get_option( 'lifterlms_myaccount_grades_endpoint', 'my-grades' ), + 'paginate' => true, + 'nav_item' => true, + 'title' => __( 'My Grades', 'lifterlms' ), + ), + 'view-memberships' => array( + 'content' => 'lifterlms_template_student_dashboard_my_memberships', + 'endpoint' => get_option( 'lifterlms_myaccount_memberships_endpoint', 'view-memberships' ), + 'nav_item' => true, + 'title' => __( 'My Memberships', 'lifterlms' ), + ), + 'view-achievements' => array( + 'content' => 'lifterlms_template_student_dashboard_my_achievements', + 'endpoint' => get_option( 'lifterlms_myaccount_achievements_endpoint', 'view-achievements' ), + 'paginate' => true, + 'nav_item' => true, + 'title' => __( 'My Achievements', 'lifterlms' ), + ), + 'view-certificates' => array( + 'content' => 'lifterlms_template_student_dashboard_my_certificates', + 'endpoint' => get_option( 'lifterlms_myaccount_certificates_endpoint', 'view-certificates' ), + 'paginate' => true, + 'nav_item' => true, + 'title' => __( 'My Certificates', 'lifterlms' ), + ), + 'notifications' => array( + 'content' => 'lifterlms_template_student_dashboard_my_notifications', + 'endpoint' => get_option( 'lifterlms_myaccount_notifications_endpoint', 'notifications' ), + 'paginate' => true, + 'nav_item' => true, + 'title' => __( 'Notifications', 'lifterlms' ), + ), + 'edit-account' => array( + 'content' => array( __CLASS__, 'output_edit_account_content' ), + 'endpoint' => get_option( 'lifterlms_myaccount_edit_account_endpoint', 'edit-account' ), + 'nav_item' => true, + 'title' => __( 'Edit Account', 'lifterlms' ), + ), + 'redeem-voucher' => array( + 'content' => array( __CLASS__, 'output_redeem_voucher_content' ), + 'endpoint' => get_option( 'lifterlms_myaccount_redeem_vouchers_endpoint', 'redeem-voucher' ), + 'nav_item' => true, + 'title' => __( 'Redeem a Voucher', 'lifterlms' ), + ), + 'orders' => array( + 'content' => array( __CLASS__, 'output_orders_content' ), + 'endpoint' => get_option( 'lifterlms_myaccount_orders_endpoint', 'orders' ), + 'nav_item' => true, + 'title' => __( 'Order History', 'lifterlms' ), + ), + 'signout' => array( + 'endpoint' => false, + 'title' => __( 'Sign Out', 'lifterlms' ), + 'nav_item' => false, + 'url' => wp_logout_url( llms_get_page_url( 'myaccount' ) ), + ), + ); + + if ( llms_is_favorites_enabled() ) { + $tabs = llms_assoc_array_insert( + $tabs, + 'view-certificates', + 'view-favorites', + array( 'content' => 'llms_template_student_dashboard_my_favorites', 'endpoint' => get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ), 'paginate' => true, 'nav_item' => true, 'title' => __( 'My Favorites', 'lifterlms' ), - ), - 'notifications' => array( - 'content' => 'lifterlms_template_student_dashboard_my_notifications', - 'endpoint' => get_option( 'lifterlms_myaccount_notifications_endpoint', 'notifications' ), - 'paginate' => true, - 'nav_item' => true, - 'title' => __( 'Notifications', 'lifterlms' ), - ), - 'edit-account' => array( - 'content' => array( __CLASS__, 'output_edit_account_content' ), - 'endpoint' => get_option( 'lifterlms_myaccount_edit_account_endpoint', 'edit-account' ), - 'nav_item' => true, - 'title' => __( 'Edit Account', 'lifterlms' ), - ), - 'redeem-voucher' => array( - 'content' => array( __CLASS__, 'output_redeem_voucher_content' ), - 'endpoint' => get_option( 'lifterlms_myaccount_redeem_vouchers_endpoint', 'redeem-voucher' ), - 'nav_item' => true, - 'title' => __( 'Redeem a Voucher', 'lifterlms' ), - ), - 'orders' => array( - 'content' => array( __CLASS__, 'output_orders_content' ), - 'endpoint' => get_option( 'lifterlms_myaccount_orders_endpoint', 'orders' ), - 'nav_item' => true, - 'title' => __( 'Order History', 'lifterlms' ), - ), - 'signout' => array( - 'endpoint' => false, - 'title' => __( 'Sign Out', 'lifterlms' ), - 'nav_item' => false, - 'url' => wp_logout_url( llms_get_page_url( 'myaccount' ) ), - ), - ) + ) + ); + } + + return apply_filters( + 'llms_get_student_dashboard_tabs', + $tabs ); } From 84c01bc3710a62dcdf5ccf3b4b919d4d068cec97 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 14:23:10 +0100 Subject: [PATCH 057/522] improve favorites count --- includes/functions/llms.functions.favorite.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/includes/functions/llms.functions.favorite.php b/includes/functions/llms.functions.favorite.php index 19c965f94c..ce771aabdf 100644 --- a/includes/functions/llms.functions.favorite.php +++ b/includes/functions/llms.functions.favorite.php @@ -27,18 +27,16 @@ function llms_get_object_total_favorites( $object_id = false ) { $object_id = get_the_ID(); } - // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $res = $wpdb->get_results( // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching + $res = $wpdb->get_var( $wpdb->prepare( - "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta + "SELECT COUNT(DISTINCT meta_id) FROM {$wpdb->prefix}lifterlms_user_postmeta WHERE post_id = %d AND meta_key = %s ORDER BY updated_date DESC", $object_id, '_favorite' ) - ); - // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared + ); // db call ok; no-cache ok. - return count( $res ); + return $res; } From ada5bd1cc0bebe3445e70bfdb36399ea8d147740 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 15:08:07 +0100 Subject: [PATCH 058/522] phpcs --- includes/class.llms.ajax.php | 4 ++-- includes/shortcodes/class.llms.shortcode.favorites.php | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/includes/class.llms.ajax.php b/includes/class.llms.ajax.php index 692c6049a3..d0ca589aef 100644 --- a/includes/class.llms.ajax.php +++ b/includes/class.llms.ajax.php @@ -210,7 +210,7 @@ public function query_quiz_questions() { } /** - * Add Favorite / Unfavorite Postmeta for an object. + * Add Favorite / Unfavorite postmeta for an object. * * @since [version] * @@ -238,7 +238,7 @@ public function favorite_object() { } - echo json_encode( + echo wp_json_encode( array( 'total_favorites' => llms_get_object_total_favorites( $object_id ), 'success' => true, diff --git a/includes/shortcodes/class.llms.shortcode.favorites.php b/includes/shortcodes/class.llms.shortcode.favorites.php index f382cc8456..661305eca3 100644 --- a/includes/shortcodes/class.llms.shortcode.favorites.php +++ b/includes/shortcodes/class.llms.shortcode.favorites.php @@ -82,15 +82,13 @@ protected function get_output() { if ( ! llms_get_student() ) { printf( + // Translators: 1%$s = Opening anchor tag; %2$s = Closing anchor tag. esc_html__( 'You must be logged in to view this information. Click %1$shere%2$s to login.', 'lifterlms' ), '', '' ); - } else { - $favorites = $this->get_favorites(); - llms_template_my_favorites_loop( get_current_user_id(), $favorites ); } From 6335895d9147dc8191afe8eefd5ae529ac984f48 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 15:49:44 +0100 Subject: [PATCH 059/522] Improve method `LLMS_Student::get_favorites()` method. --- includes/models/model.llms.student.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/includes/models/model.llms.student.php b/includes/models/model.llms.student.php index da0557287e..c1e7893857 100644 --- a/includes/models/model.llms.student.php +++ b/includes/models/model.llms.student.php @@ -270,23 +270,22 @@ public function get_courses( $args = array() ) { * * @since [version] * - * @param string $order_by Result set ordering field. Default "date". + * @param string $order_by Result set ordering field. Default "updated_date". * @param string $order Result set order. Default "DESC". Accepts "DESC" or "ASC". - * @param int $limit Number of favorites to return. + * @param int $limit Number of favorites to return. Default is infinite. * @return bool|array */ - public function get_favorites( $order_by = '', $order = '', $limit = '' ) { + public function get_favorites( $order_by = 'updated_date', $order = 'DESC', $limit = -1 ) { global $wpdb; - $order_by = ( '' === $order_by ) ? '' : 'ORDER BY ' . $order_by; - $limit = ( '' === $limit ) ? '' : 'LIMIT ' . $limit; + $limit_clause = $limit < 1 ? '' : "LIMIT 0, {$limit}"; // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared $res = $wpdb->get_results( $wpdb->prepare( "SELECT * FROM {$wpdb->prefix}lifterlms_user_postmeta - WHERE meta_key = %s AND user_id = %d $order_by $order $limit", + WHERE meta_key = %s AND user_id = %d ORDER BY {$order_by} {$order} {$limit_clause};", '_favorite', get_current_user_id() ) From 630ed6383816faf1def308da4a889f654f916bfd Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 15:58:33 +0100 Subject: [PATCH 060/522] Move favorites setting into the Courses settings, improve account endpoint settings --- .../settings/class.llms.settings.accounts.php | 613 +++++++++--------- .../settings/class.llms.settings.courses.php | 24 +- .../settings/class.llms.settings.general.php | 11 +- 3 files changed, 337 insertions(+), 311 deletions(-) diff --git a/includes/admin/settings/class.llms.settings.accounts.php b/includes/admin/settings/class.llms.settings.accounts.php index d3f86f3c06..f583b2664f 100644 --- a/includes/admin/settings/class.llms.settings.accounts.php +++ b/includes/admin/settings/class.llms.settings.accounts.php @@ -51,309 +51,328 @@ class LLMS_Settings_Accounts extends LLMS_Settings_Page { * @return array */ public function get_settings() { - return apply_filters( - 'lifterlms_' . $this->id . '_settings', + $account_settings = array( array( - array( - 'class' => 'top', - 'id' => 'course_account_options', - 'type' => 'sectionstart', - ), - array( - 'id' => 'account_page_options_start', - 'title' => __( 'Student Dashboard', 'lifterlms' ), - 'type' => 'title', - ), - array( - 'title' => __( 'Dashboard Page', 'lifterlms' ), - 'desc' => __( 'Page where students can view and manage their current enrollments, earned certificates and achievements, account information, and purchase history.', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_page_id', - 'default' => '', - 'desc_tip' => true, - 'class' => 'llms-select2-post', - 'type' => 'select', - 'custom_attributes' => array( - 'data-post-type' => 'page', - ), - 'options' => llms_make_select2_post_array( get_option( 'lifterlms_myaccount_page_id', '' ) ), - ), - array( - 'title' => __( 'Courses Sorting', 'lifterlms' ), - 'default' => 'order,ASC', - 'desc' => __( 'Determines the order of the courses in-progress listed on the student dashboard.', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_courses_in_progress_sorting', - 'type' => 'select', - 'options' => array( - 'title,ASC' => __( 'Course Title (A to Z)', 'lifterlms' ), - 'title,DESC' => __( 'Course Title (Z to A)', 'lifterlms' ), - 'date,DESC' => __( 'Enrollment Date (Most Recent to Least Recent)', 'lifterlms' ), - 'order,ASC' => __( 'Order (Low to High)', 'lifterlms' ), - 'order,DESC' => __( 'Order (High to Low)', 'lifterlms' ), - ), - ), - array( - 'default' => 'no', - 'desc' => sprintf( - // Translators: %1$s = opening anchor tag; %2$s = closing anchor tag. - __( 'Enable new user registration on the Student Dashboard. %1$sLearn More%2$s.', 'lifterlms' ), - '', - '' - ), - 'id' => 'lifterlms_enable_myaccount_registration', - 'title' => __( 'Open Registration', 'lifterlms' ), - 'type' => 'checkbox', - ), - array( - 'default' => 'no', - 'desc' => __( 'Only allow the most recent login for each user account.', 'lifterlms' ), - 'id' => 'lifterlms_prevent_concurrent_logins', - 'title' => __( 'Prevent concurrent logins', 'lifterlms' ), - 'type' => 'checkbox', - 'custom_attributes' => array( - 'class' => 'llms-conditional-controller', - 'data-controls' => '#lifterlms_prevent_concurrent_logins_roles', - ), - ), - array( - 'class' => 'llms-select2', - 'default' => array( 'student' ), - 'desc' => __( 'Prevent concurrent logins for users with the selected user roles.', 'lifterlms' ), - 'id' => 'lifterlms_prevent_concurrent_logins_roles', - 'options' => LLMS_Roles::get_all_role_names(), - 'title' => '', - 'type' => 'multiselect', - 'custom_attributes' => array( - 'data-placeholder' => __( 'Select user roles', 'lifterlms' ), - ), - ), - array( - 'id' => 'course_account_options_end', - 'type' => 'sectionend', - ), - array( - 'class' => 'top', - 'id' => 'course_account_endpoint_options_start', - 'type' => 'sectionstart', - ), - array( - 'id' => 'account_page_endpoint_options_title', - 'title' => __( 'Student Dashboard Endpoints', 'lifterlms' ), - 'desc' => __( 'Each endpoint allows students to view more information or manage parts of their account. Each endpoint should be unique, URL-safe, and can be left blank to disable the endpoint completely.', 'lifterlms' ), - 'type' => 'title', - ), - array( - 'title' => __( 'View Grades', 'lifterlms' ), - 'desc' => __( 'Student grade and progress reporting', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_grades_endpoint', - 'type' => 'text', - 'default' => 'my-grades', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'View Courses', 'lifterlms' ), - 'desc' => __( 'List of all the student\'s courses', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_courses_endpoint', - 'type' => 'text', - 'default' => 'my-courses', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'View Memberships', 'lifterlms' ), - 'desc' => __( 'List of all the student\'s memberships', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_memberships_endpoint', - 'type' => 'text', - 'default' => 'my-memberships', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'View Achievements', 'lifterlms' ), - 'desc' => __( 'List of all the student\'s achievements', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_achievements_endpoint', - 'type' => 'text', - 'default' => 'my-achievements', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'View Certificates', 'lifterlms' ), - 'desc' => __( 'List of all the student\'s certificates', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_certificates_endpoint', - 'type' => 'text', - 'default' => 'my-certificates', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'View Favorites', 'lifterlms' ), - 'desc' => __( 'List of all the student\'s favorites', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_favorites_endpoint', - 'type' => 'text', - 'default' => 'my-favorites', - 'sanitize' => 'slug', - 'disabled' => ! llms_is_favorites_enabled() ? true : false, - ), - array( - 'title' => __( 'Notifications', 'lifterlms' ), - 'desc' => __( 'View Notifications and adjust notification settings', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_notifications_endpoint', - 'type' => 'text', - 'default' => 'notifications', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'Edit Account', 'lifterlms' ), - 'desc' => __( 'Edit Account page', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_edit_account_endpoint', - 'type' => 'text', - 'default' => 'edit-account', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'Lost Password', 'lifterlms' ), - 'desc' => __( 'Lost Password page', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_lost_password_endpoint', - 'type' => 'text', - 'default' => 'lost-password', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'Redeem Vouchers', 'lifterlms' ), - 'desc' => __( 'Redeem vouchers page', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_redeem_vouchers_endpoint', - 'type' => 'text', - 'default' => 'redeem-voucher', - 'sanitize' => 'slug', - ), - array( - 'title' => __( 'Orders History', 'lifterlms' ), - 'desc' => __( 'Students can review order history on this page', 'lifterlms' ), - 'id' => 'lifterlms_myaccount_orders_endpoint', - 'type' => 'text', - 'default' => 'orders', - 'sanitize' => 'slug', - ), - array( - 'id' => 'course_account_endpoint_options_end', - 'type' => 'sectionend', - ), + 'class' => 'top', + 'id' => 'course_account_options', + 'type' => 'sectionstart', + ), + array( + 'id' => 'account_page_options_start', + 'title' => __( 'Student Dashboard', 'lifterlms' ), + 'type' => 'title', + ), + array( + 'title' => __( 'Dashboard Page', 'lifterlms' ), + 'desc' => __( 'Page where students can view and manage their current enrollments, earned certificates and achievements, account information, and purchase history.', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_page_id', + 'default' => '', + 'desc_tip' => true, + 'class' => 'llms-select2-post', + 'type' => 'select', + 'custom_attributes' => array( + 'data-post-type' => 'page', + ), + 'options' => llms_make_select2_post_array( get_option( 'lifterlms_myaccount_page_id', '' ) ), + ), + array( + 'title' => __( 'Courses Sorting', 'lifterlms' ), + 'default' => 'order,ASC', + 'desc' => __( 'Determines the order of the courses in-progress listed on the student dashboard.', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_courses_in_progress_sorting', + 'type' => 'select', + 'options' => array( + 'title,ASC' => __( 'Course Title (A to Z)', 'lifterlms' ), + 'title,DESC' => __( 'Course Title (Z to A)', 'lifterlms' ), + 'date,DESC' => __( 'Enrollment Date (Most Recent to Least Recent)', 'lifterlms' ), + 'order,ASC' => __( 'Order (Low to High)', 'lifterlms' ), + 'order,DESC' => __( 'Order (High to Low)', 'lifterlms' ), + ), + ), + array( + 'default' => 'no', + 'desc' => sprintf( + // Translators: %1$s = opening anchor tag; %2$s = closing anchor tag. + __( 'Enable new user registration on the Student Dashboard. %1$sLearn More%2$s.', 'lifterlms' ), + '', + '' + ), + 'id' => 'lifterlms_enable_myaccount_registration', + 'title' => __( 'Open Registration', 'lifterlms' ), + 'type' => 'checkbox', + ), + array( + 'default' => 'no', + 'desc' => __( 'Only allow the most recent login for each user account.', 'lifterlms' ), + 'id' => 'lifterlms_prevent_concurrent_logins', + 'title' => __( 'Prevent concurrent logins', 'lifterlms' ), + 'type' => 'checkbox', + 'custom_attributes' => array( + 'class' => 'llms-conditional-controller', + 'data-controls' => '#lifterlms_prevent_concurrent_logins_roles', + ), + ), + array( + 'class' => 'llms-select2', + 'default' => array( 'student' ), + 'desc' => __( 'Prevent concurrent logins for users with the selected user roles.', 'lifterlms' ), + 'id' => 'lifterlms_prevent_concurrent_logins_roles', + 'options' => LLMS_Roles::get_all_role_names(), + 'title' => '', + 'type' => 'multiselect', + 'custom_attributes' => array( + 'data-placeholder' => __( 'Select user roles', 'lifterlms' ), + ), + ), + array( + 'id' => 'course_account_options_end', + 'type' => 'sectionend', + ), + array( + 'class' => 'top', + 'id' => 'course_account_endpoint_options_start', + 'type' => 'sectionstart', + ), + array( + 'id' => 'account_page_endpoint_options_title', + 'title' => __( 'Student Dashboard Endpoints', 'lifterlms' ), + 'desc' => __( 'Each endpoint allows students to view more information or manage parts of their account. Each endpoint should be unique, URL-safe, and can be left blank to disable the endpoint completely.', 'lifterlms' ), + 'type' => 'title', + ), + array( + 'title' => __( 'View Grades', 'lifterlms' ), + 'desc' => __( 'Student grade and progress reporting', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_grades_endpoint', + 'type' => 'text', + 'default' => 'my-grades', + 'sanitize' => 'slug', + ), + array( + 'title' => __( 'View Courses', 'lifterlms' ), + 'desc' => __( 'List of all the student\'s courses', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_courses_endpoint', + 'type' => 'text', + 'default' => 'my-courses', + 'sanitize' => 'slug', + ), + array( + 'title' => __( 'View Memberships', 'lifterlms' ), + 'desc' => __( 'List of all the student\'s memberships', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_memberships_endpoint', + 'type' => 'text', + 'default' => 'my-memberships', + 'sanitize' => 'slug', + ), + array( + 'title' => __( 'View Achievements', 'lifterlms' ), + 'desc' => __( 'List of all the student\'s achievements', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_achievements_endpoint', + 'type' => 'text', + 'default' => 'my-achievements', + 'sanitize' => 'slug', + ), + array( + 'title' => __( 'View Certificates', 'lifterlms' ), + 'desc' => __( 'List of all the student\'s certificates', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_certificates_endpoint', + 'type' => 'text', + 'default' => 'my-certificates', + 'sanitize' => 'slug', + ), - // Start user info fields options. - array( - 'id' => 'user_info_field_options', - 'type' => 'sectionstart', - ), - array( - 'title' => __( 'User Information & Privacy Options', 'lifterlms' ), - 'type' => 'title', - 'id' => 'user_info_field_options_title', - ), + array( + 'title' => __( 'Notifications', 'lifterlms' ), + 'desc' => __( 'View Notifications and adjust notification settings', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_notifications_endpoint', + 'type' => 'text', + 'default' => 'notifications', + 'sanitize' => 'slug', + ), + array( + 'title' => __( 'Edit Account', 'lifterlms' ), + 'desc' => __( 'Edit Account page', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_edit_account_endpoint', + 'type' => 'text', + 'default' => 'edit-account', + 'sanitize' => 'slug', + ), + array( + 'title' => __( 'Lost Password', 'lifterlms' ), + 'desc' => __( 'Lost Password page', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_lost_password_endpoint', + 'type' => 'text', + 'default' => 'lost-password', + 'sanitize' => 'slug', + ), + array( + 'title' => __( 'Redeem Vouchers', 'lifterlms' ), + 'desc' => __( 'Redeem vouchers page', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_redeem_vouchers_endpoint', + 'type' => 'text', + 'default' => 'redeem-voucher', + 'sanitize' => 'slug', + ), + array( + 'title' => __( 'Orders History', 'lifterlms' ), + 'desc' => __( 'Students can review order history on this page', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_orders_endpoint', + 'type' => 'text', + 'default' => 'orders', + 'sanitize' => 'slug', + ), + array( + 'id' => 'course_account_endpoint_options_end', + 'type' => 'sectionend', + ), - array( - 'title' => __( 'User Information Field Settings', 'lifterlms' ), - 'type' => 'subtitle', - 'desc' => __( 'Since version 5.0, all user information fields are customized using the form editor.', 'lifterlms' ), - ), - array( - 'type' => 'custom-html', - 'value' => '

' . __( 'Edit Forms', 'lifterlms' ) . '

', - ), + // Start user info fields options. + array( + 'id' => 'user_info_field_options', + 'type' => 'sectionstart', + ), + array( + 'title' => __( 'User Information & Privacy Options', 'lifterlms' ), + 'type' => 'title', + 'id' => 'user_info_field_options_title', + ), - array( - 'title' => __( 'Terms and Conditions', 'lifterlms' ), - 'type' => 'subtitle', - ), - array( - 'autoload' => false, - 'default' => 'no', - 'id' => 'lifterlms_registration_require_agree_to_terms', - 'desc' => __( 'When enabled users must agree to your site\'s Terms and Conditions to register for an account.', 'lifterlms' ), - 'title' => __( 'Enable / Disable', 'lifterlms' ), - 'type' => 'checkbox', - 'custom_attributes' => array( - 'class' => 'llms-conditional-controller', - 'data-controls' => '#lifterlms_terms_page_id,#llms_terms_notice', - ), - ), - array( - 'autoload' => false, - 'desc' => __( 'Select a page where your site\'s Terms and Conditions are described.', 'lifterlms' ), - 'id' => 'lifterlms_terms_page_id', - 'default' => '', - 'desc_tip' => true, - 'class' => 'llms-select2-post', - 'title' => __( 'Terms and Conditions Page', 'lifterlms' ), - 'type' => 'select', - 'custom_attributes' => array( - 'data-post-type' => 'page', - 'data-placeholder' => __( 'Select a page', 'lifterlms' ), - ), - 'options' => llms_make_select2_post_array( get_option( 'lifterlms_terms_page_id', '' ) ), - ), - array( - 'autoload' => false, - 'default' => llms_get_terms_notice(), - 'id' => 'llms_terms_notice', - 'desc' => __( 'Customize the text used to display the Terms and Conditions checkbox that students must accept.', 'lifterlms' ), - 'title' => __( 'Terms and Conditions Notice', 'lifterlms' ), - 'type' => 'textarea', - 'value' => llms_get_terms_notice(), - ), - array( - 'title' => __( 'Privacy Policy', 'lifterlms' ), - 'type' => 'subtitle', - ), - array( - 'autoload' => false, - 'desc' => sprintf( - __( 'Select a page where your site\'s Privacy Policy is described. See %1$sWordPress Privacy Settings%2$s for more information', 'lifterlms' ), - '', - '' - ), - 'id' => 'wp_page_for_privacy_policy', - 'class' => 'llms-select2-post', - 'title' => __( 'Privacy Policy Page', 'lifterlms' ), - 'type' => 'select', - 'custom_attributes' => array( - 'data-post-type' => 'page', - 'data-placeholder' => __( 'Select a page', 'lifterlms' ), - ), - 'options' => llms_make_select2_post_array( get_option( 'wp_page_for_privacy_policy' ) ), - ), - array( - 'autoload' => false, - 'default' => llms_get_privacy_notice(), - 'id' => 'llms_privacy_notice', - 'desc' => __( 'Optionally display a privacy policy notice during registration and checkout.', 'lifterlms' ), - 'title' => __( 'Privacy Policy Notice', 'lifterlms' ), - 'type' => 'textarea', - ), - array( - 'title' => __( 'Account Erasure Requests', 'lifterlms' ), - /* Translators: %$1s = opening anchor to account erasure screen; %2$s closing anchor */ - 'desc' => sprintf( __( 'Customize data retention during %1$saccount erasure requests%2$s.', 'lifterlms' ), '', '' ), - 'type' => 'subtitle', - ), - array( - 'autoload' => false, - 'default' => 'no', - 'id' => 'llms_erasure_request_removes_order_data', - 'desc' => __( 'When enabled orders will be anonymized during a personal data erasure.', 'lifterlms' ), - 'title' => __( 'Remove Order Data', 'lifterlms' ), - 'type' => 'checkbox', - ), - array( - 'autoload' => false, - 'default' => 'no', - 'id' => 'llms_erasure_request_removes_lms_data', - 'desc' => __( 'When enabled all student data related to course and membership activities will be removed.', 'lifterlms' ), - 'title' => __( 'Remove Student LMS Data', 'lifterlms' ), - 'type' => 'checkbox', - ), - array( - 'id' => 'user_info_field_options_end', - 'type' => 'sectionend', - ), + array( + 'title' => __( 'User Information Field Settings', 'lifterlms' ), + 'type' => 'subtitle', + 'desc' => __( 'Since version 5.0, all user information fields are customized using the form editor.', 'lifterlms' ), + ), + array( + 'type' => 'custom-html', + 'value' => '

' . __( 'Edit Forms', 'lifterlms' ) . '

', + ), + + array( + 'title' => __( 'Terms and Conditions', 'lifterlms' ), + 'type' => 'subtitle', + ), + array( + 'autoload' => false, + 'default' => 'no', + 'id' => 'lifterlms_registration_require_agree_to_terms', + 'desc' => __( 'When enabled users must agree to your site\'s Terms and Conditions to register for an account.', 'lifterlms' ), + 'title' => __( 'Enable / Disable', 'lifterlms' ), + 'type' => 'checkbox', + 'custom_attributes' => array( + 'class' => 'llms-conditional-controller', + 'data-controls' => '#lifterlms_terms_page_id,#llms_terms_notice', + ), + ), + array( + 'autoload' => false, + 'desc' => __( 'Select a page where your site\'s Terms and Conditions are described.', 'lifterlms' ), + 'id' => 'lifterlms_terms_page_id', + 'default' => '', + 'desc_tip' => true, + 'class' => 'llms-select2-post', + 'title' => __( 'Terms and Conditions Page', 'lifterlms' ), + 'type' => 'select', + 'custom_attributes' => array( + 'data-post-type' => 'page', + 'data-placeholder' => __( 'Select a page', 'lifterlms' ), + ), + 'options' => llms_make_select2_post_array( get_option( 'lifterlms_terms_page_id', '' ) ), + ), + array( + 'autoload' => false, + 'default' => llms_get_terms_notice(), + 'id' => 'llms_terms_notice', + 'desc' => __( 'Customize the text used to display the Terms and Conditions checkbox that students must accept.', 'lifterlms' ), + 'title' => __( 'Terms and Conditions Notice', 'lifterlms' ), + 'type' => 'textarea', + 'value' => llms_get_terms_notice(), + ), + array( + 'title' => __( 'Privacy Policy', 'lifterlms' ), + 'type' => 'subtitle', + ), + array( + 'autoload' => false, + 'desc' => sprintf( + __( 'Select a page where your site\'s Privacy Policy is described. See %1$sWordPress Privacy Settings%2$s for more information', 'lifterlms' ), + '', + '' + ), + 'id' => 'wp_page_for_privacy_policy', + 'class' => 'llms-select2-post', + 'title' => __( 'Privacy Policy Page', 'lifterlms' ), + 'type' => 'select', + 'custom_attributes' => array( + 'data-post-type' => 'page', + 'data-placeholder' => __( 'Select a page', 'lifterlms' ), + ), + 'options' => llms_make_select2_post_array( get_option( 'wp_page_for_privacy_policy' ) ), + ), + array( + 'autoload' => false, + 'default' => llms_get_privacy_notice(), + 'id' => 'llms_privacy_notice', + 'desc' => __( 'Optionally display a privacy policy notice during registration and checkout.', 'lifterlms' ), + 'title' => __( 'Privacy Policy Notice', 'lifterlms' ), + 'type' => 'textarea', + ), + array( + 'title' => __( 'Account Erasure Requests', 'lifterlms' ), + /* Translators: %$1s = opening anchor to account erasure screen; %2$s closing anchor */ + 'desc' => sprintf( __( 'Customize data retention during %1$saccount erasure requests%2$s.', 'lifterlms' ), '', '' ), + 'type' => 'subtitle', + ), + array( + 'autoload' => false, + 'default' => 'no', + 'id' => 'llms_erasure_request_removes_order_data', + 'desc' => __( 'When enabled orders will be anonymized during a personal data erasure.', 'lifterlms' ), + 'title' => __( 'Remove Order Data', 'lifterlms' ), + 'type' => 'checkbox', + ), + array( + 'autoload' => false, + 'default' => 'no', + 'id' => 'llms_erasure_request_removes_lms_data', + 'desc' => __( 'When enabled all student data related to course and membership activities will be removed.', 'lifterlms' ), + 'title' => __( 'Remove Student LMS Data', 'lifterlms' ), + 'type' => 'checkbox', + ), + array( + 'id' => 'user_info_field_options_end', + 'type' => 'sectionend', + ), - ) ); + + if ( llms_is_favorites_enabled() ) { + array_splice( + $account_settings, + 15, + 0, + array( + array( + 'title' => __( 'View Favorites', 'lifterlms' ), + 'desc' => __( 'List of all the student\'s favorites', 'lifterlms' ), + 'id' => 'lifterlms_myaccount_favorites_endpoint', + 'type' => 'text', + 'default' => 'my-favorites', + 'sanitize' => 'slug', + ), + ) + ); + } + + /** + * Filters the account settings. + * + * The dynamic portion of this filter `{$this->id}` refers to the unique ID for the settings page. + * + * @since Unknown + * + * @param array $account_settings The account page settings. + */ + return apply_filters( "lifterlms_{$this->id}_settings", $account_settings ); + } /** diff --git a/includes/admin/settings/class.llms.settings.courses.php b/includes/admin/settings/class.llms.settings.courses.php index d2b3ba9628..a3220a3502 100644 --- a/includes/admin/settings/class.llms.settings.courses.php +++ b/includes/admin/settings/class.llms.settings.courses.php @@ -5,7 +5,7 @@ * @package LifterLMS/Admin/Settings/Classes * * @since 3.5.0 - * @version 3.5.0 + * @version [version] */ defined( 'ABSPATH' ) || exit; @@ -38,14 +38,22 @@ public function __construct() { } /** - * Get settings array + * Get settings array. + * + * @since 3.5.0 + * @since [version] Added settings for enabling/disabling favorites. * * @return array - * @since 3.5.0 - * @version 3.5.0 */ public function get_settings() { + /** + * Filter the course settings. + * + * @since 3.5.0 + * + * @param array $course_settings THe course Settings. + */ $course = apply_filters( 'lifterlms_course_settings', array( @@ -70,6 +78,14 @@ public function get_settings() { 'type' => 'checkbox', ), + array( + 'title' => __( 'Lesson Favorites', 'lifterlms' ), + 'desc' => __( 'Enabling this setting allows students to mark a lesson as "favorite".', 'lifterlms' ), + 'id' => 'lifterlms_favorites', + 'default' => 'no', + 'type' => 'checkbox', + ), + array( 'type' => 'sectionend', 'id' => 'course_general_options', diff --git a/includes/admin/settings/class.llms.settings.general.php b/includes/admin/settings/class.llms.settings.general.php index f1a5f897d9..5e05276fbf 100644 --- a/includes/admin/settings/class.llms.settings.general.php +++ b/includes/admin/settings/class.llms.settings.general.php @@ -5,7 +5,7 @@ * @package LifterLMS/Admin/Settings/Classes * * @since 1.0.0 - * @version [version] + * @version 5.6.0 */ defined( 'ABSPATH' ) || exit; @@ -45,7 +45,6 @@ public function __construct() { * @since 3.13.0 Unknown. * @since 5.6.0 use LLMS_Roles::get_all_role_names() to retrieve the list of roles who can bypass enrollments. * Add content protection setting. - * @since [version] Added settings for enabling/disabling favorites. * * @return array */ @@ -73,14 +72,6 @@ public function get_settings() { ), ); - $settings[] = array( - 'title' => __( 'Lesson Favorites', 'lifterlms' ), - 'desc' => __( 'Enabling this setting allows students to mark a lesson as "favorite".', 'lifterlms' ), - 'id' => 'lifterlms_favorites', - 'default' => 'no', - 'type' => 'checkbox', - ); - $settings[] = array( 'id' => 'section_features', 'type' => 'sectionend', From 31ae23bcba35856b7c45e71ac8f7defb18d0566a Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 15:59:51 +0100 Subject: [PATCH 061/522] improve templating logic --- includes/llms.template.functions.php | 18 ++++++++---------- includes/llms.template.hooks.php | 5 ++++- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index f85b4c12f5..28d2637954 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -398,16 +398,14 @@ function lifterlms_template_single_parent_course() { */ function llms_template_favorite( $object_id = null, $object_type = 'lesson' ) { - if ( llms_is_favorites_enabled() ) { - - llms_get_template( - 'course/favorite.php', - array( - 'object_id' => $object_id, - 'object_type' => $object_type, - ) - ); - } + llms()->assets->enqueue_script( 'llms-favorites' ); + llms_get_template( + 'course/favorite.php', + array( + 'object_id' => $object_id, + 'object_type' => $object_type, + ) + ); } } diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index 3cd3404e17..83478e8b1f 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -46,9 +46,12 @@ * Single Lesson * * @since Unknown + * @since [version] Maybe add favorite template. */ add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_parent_course', 10 ); -add_action( 'lifterlms_single_lesson_before_summary', 'llms_template_favorite', 10 ); +if ( llms_is_favorites_enabled() ) { + add_action( 'lifterlms_single_lesson_before_summary', 'llms_template_favorite', 10 ); +} add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_video', 20 ); add_action( 'lifterlms_single_lesson_before_summary', 'lifterlms_template_single_lesson_audio', 20 ); From 97418b2c5e32bbf8d7cbe42fa0b483b5ba01f4d9 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 16:19:13 +0100 Subject: [PATCH 062/522] improve templating logic with hooks --- .changelogs/feature_favorite-4.yml | 4 ++++ .changelogs/feature_favorite-5.yml | 3 +++ includes/class.llms.frontend.assets.php | 1 + includes/llms.template.functions.php | 16 ++++++++++++++++ includes/llms.template.hooks.php | 9 +++++++++ templates/course/lesson-preview.php | 21 ++++++++++++++------- 6 files changed, 47 insertions(+), 7 deletions(-) create mode 100644 .changelogs/feature_favorite-4.yml create mode 100644 .changelogs/feature_favorite-5.yml diff --git a/.changelogs/feature_favorite-4.yml b/.changelogs/feature_favorite-4.yml new file mode 100644 index 0000000000..f61c17c96b --- /dev/null +++ b/.changelogs/feature_favorite-4.yml @@ -0,0 +1,4 @@ +significance: patch +type: dev +entry: Added `llms_lesson_preview_before_title` and + `llms_lesson_preview_after_title` action hooks. diff --git a/.changelogs/feature_favorite-5.yml b/.changelogs/feature_favorite-5.yml new file mode 100644 index 0000000000..a914bb2c31 --- /dev/null +++ b/.changelogs/feature_favorite-5.yml @@ -0,0 +1,3 @@ +significance: patch +type: dev +entry: Added function `llms_template_syllabus_syllabus_lesson_preview`. diff --git a/includes/class.llms.frontend.assets.php b/includes/class.llms.frontend.assets.php index b91b7b1ef3..1d625fd592 100644 --- a/includes/class.llms.frontend.assets.php +++ b/includes/class.llms.frontend.assets.php @@ -201,6 +201,7 @@ public static function enqueue_scripts() { llms()->assets->enqueue_script( 'llms-quiz' ); } + llms()->assets->register_script( 'llms-favorites' ); if ( ( is_lesson() || is_course() ) && true === llms_is_favorites_enabled() ) { llms()->assets->enqueue_script( 'llms-favorites' ); } diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index 28d2637954..b4db782c7a 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -409,6 +409,22 @@ function llms_template_favorite( $object_id = null, $object_type = 'lesson' ) { } } +if ( ! function_exists( 'llms_template_syllabus_favorite_lesson_preview' ) ) { + + /** + * Favorite Lesson Template Include when displayed in the syllabus lesson preview. + * + * @since [version] + * + * @return void + */ + function llms_template_syllabus_syllabus_lesson_preview( $lesson ) { + if ( 'course' === get_post_type( get_the_ID() ) ) { + llms_template_favorite( $lesson->get( 'id' ) ); + } + } +} + /** * Complete Lesson Link Template Include * diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index 83478e8b1f..83e1af763c 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -87,6 +87,15 @@ add_action( 'lifterlms_after_loop_item', 'lifterlms_loop_link_end', 5 ); +/** + * Course Syllabus + * + * @since [version] + */ +if ( llms_is_favorites_enabled() ) { + add_action( 'llms_lesson_preview_after_title', 'llms_template_syllabus_syllabus_lesson_preview', 10 ); +} + /** * Emails * diff --git a/templates/course/lesson-preview.php b/templates/course/lesson-preview.php index a3fa37a396..788eb27944 100644 --- a/templates/course/lesson-preview.php +++ b/templates/course/lesson-preview.php @@ -9,7 +9,7 @@ * @since 3.19.2 Unknown. * @since 4.4.0 Use the passed `$order` param if available, in favor of retrieving the lesson's order post meta. * @since 5.7.0 Replaced the call to the deprecated `LLMS_Lesson::get_order()` method with `LLMS_Lesson::get( 'order' )`. - * @since [version] Added Favorites function `llms_template_favorite()`. + * @since [version] Added `llms_lesson_preview_before_title` and `llms_lesson_preview_after_title` action hooks. * @version [version] * * @var LLMS_Lesson $lesson The lesson object. @@ -46,19 +46,26 @@
+
get( 'id' ) ); ?>
get( 'id' ) ); - endif; + do_action( 'llms_lesson_preview_after_title', $lesson ) ?> get( 'id' ) ) ) : ?>
get( 'id' ) ); ?>
From 39e7402589eef94e69af5b98d391b2bd4f1e310d Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 16:39:21 +0100 Subject: [PATCH 063/522] improve js --- assets/js/llms-favorites.js | 60 +++++++++++++++---------------------- 1 file changed, 24 insertions(+), 36 deletions(-) diff --git a/assets/js/llms-favorites.js b/assets/js/llms-favorites.js index 548292eb2e..dd057aad62 100644 --- a/assets/js/llms-favorites.js +++ b/assets/js/llms-favorites.js @@ -10,15 +10,8 @@ * @version [version] */ ( function( $ ) { - - var favorite = { - /** - * Main Favorite Container Element. - * - * @type {Object} - */ - $container: null, + var favorite = { /** * Bind DOM events. @@ -34,8 +27,8 @@ // Favorite clicked. $( '.llms-favorite-wrapper' ).on( 'click', function( e ) { e.preventDefault(); - let $btn = $( this ).find( '.llms-heart-btn' ); - self.favorite( $btn ); + var $btn = $( this ).find( '.llms-heart-btn' ); + $btn && self.favorite( $btn ); } ); // Adding class in Favorite's parent. @@ -47,16 +40,13 @@ * Favorite / Unfavorite an object. * * @since [version] - * + * * @param {Object} $btn jQuery object for the "Favorite / Unfavorite" button. * @return {Void} */ favorite: function( $btn ) { - this.$container = $btn.closest( '.llms-favorite-wrapper' ); - - var self = this, - object_id = $btn.attr( 'data-id' ), + var object_id = $btn.attr( 'data-id' ), object_type = $btn.attr( 'data-type' ), user_action = $btn.attr( 'data-action' ); @@ -69,32 +59,30 @@ }, beforeSend: function() {}, success: function( r ) { - + /** + * Get all the favorite buttons on the page related to the same lesson, e.g. when the syllabus + * is shown on the sidebar of a lesson or a course, in that case you will have the same favorite + * button twice. The code below makes sure both the buttons are updated. + */ + var $fav_btns = $( '[data-id='+object_id+'][data-type='+object_type+'][data-action='+user_action+']' ); if( r.success ) { - - if( 'favorite' === user_action ) { - - $btn.removeClass( 'fa-heart-o' ).addClass( 'fa-heart' ); - $( $btn ).attr( 'data-action', 'unfavorite' ); - - } else if ( 'unfavorite' === user_action ) { - - $btn.removeClass( 'fa-heart' ).addClass( 'fa-heart-o' ); - $( $btn ).attr( 'data-action', 'favorite' ); - - } - - // Updating count. - self.$container.find( '.llms-favorites-count' ).text( r.total_favorites ); - + $fav_btns.each( + function() { + if( 'favorite' === user_action ) { + $(this).removeClass( 'fa-heart-o' ).addClass( 'fa-heart' ); + $(this).attr( 'data-action', 'unfavorite' ); + } else if ( 'unfavorite' === user_action ) { + $(this).removeClass( 'fa-heart' ).addClass( 'fa-heart-o' ); + $(this).attr( 'data-action', 'favorite' ); + } + // Updating count. + $(this).closest( '.llms-favorite-wrapper' ).find( '.llms-favorites-count' ).text( r.total_favorites ); + } + ); } - } - } ); - } - }; favorite.bind(); From 2be9840fb4de971390b2591def65da874f643383 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 16:50:50 +0100 Subject: [PATCH 064/522] fix failing tests --- .../admin/settings/class-llms-test-settings-accounts.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/phpunit/unit-tests/admin/settings/class-llms-test-settings-accounts.php b/tests/phpunit/unit-tests/admin/settings/class-llms-test-settings-accounts.php index dd31b8af71..79d8cee9fb 100644 --- a/tests/phpunit/unit-tests/admin/settings/class-llms-test-settings-accounts.php +++ b/tests/phpunit/unit-tests/admin/settings/class-llms-test-settings-accounts.php @@ -48,7 +48,8 @@ protected function get_mock_settings() { $this->factory->post->create( array( 'post_type' => 'page' ) ), ); - return array( + + $settings = array( 'lifterlms_myaccount_page_id' => $pages, 'lifterlms_myaccount_courses_in_progress_sorting' => array( 'title,ASC', @@ -131,6 +132,12 @@ protected function get_mock_settings() { 'yes', ), ); + + if ( ! llms_is_favorites_enabled() ) { + unset( $settings['lifterlms_myaccount_favorites_endpoint'] ); + } + + return $settings; } } From b859255fa614162d2078a97b148ea81a4905dd02 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Wed, 1 Nov 2023 17:26:46 +0100 Subject: [PATCH 065/522] fix typo in function name --- includes/llms.template.functions.php | 2 +- includes/llms.template.hooks.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/llms.template.functions.php b/includes/llms.template.functions.php index b4db782c7a..01a55d10e6 100644 --- a/includes/llms.template.functions.php +++ b/includes/llms.template.functions.php @@ -418,7 +418,7 @@ function llms_template_favorite( $object_id = null, $object_type = 'lesson' ) { * * @return void */ - function llms_template_syllabus_syllabus_lesson_preview( $lesson ) { + function llms_template_syllabus_favorite_lesson_preview( $lesson ) { if ( 'course' === get_post_type( get_the_ID() ) ) { llms_template_favorite( $lesson->get( 'id' ) ); } diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index 83e1af763c..b50cf32be8 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -93,7 +93,7 @@ * @since [version] */ if ( llms_is_favorites_enabled() ) { - add_action( 'llms_lesson_preview_after_title', 'llms_template_syllabus_syllabus_lesson_preview', 10 ); + add_action( 'llms_lesson_preview_after_title', 'llms_template_syllabus_favorite_lesson_preview', 10 ); } /** From 049c957c6d20ad2b8496df35c72f49fed68987f5 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Thu, 2 Nov 2023 12:07:34 +0100 Subject: [PATCH 066/522] only students who can view the lesson (enrolled to the course, or free lessons) can mark a lesson as favorite --- includes/class.llms.ajax.php | 19 ++++++++++++------- templates/course/favorite.php | 23 ++++++++++++++++------- 2 files changed, 28 insertions(+), 14 deletions(-) diff --git a/includes/class.llms.ajax.php b/includes/class.llms.ajax.php index d0ca589aef..94c6538da4 100644 --- a/includes/class.llms.ajax.php +++ b/includes/class.llms.ajax.php @@ -223,19 +223,24 @@ public function favorite_object() { $object_id = llms_filter_input( INPUT_POST, 'object_id', FILTER_SANITIZE_NUMBER_INT ); $object_type = llms_filter_input_sanitize_string( INPUT_POST, 'object_type' ); $user_id = get_current_user_id(); - - if ( is_null( $object_id ) ) { + $student = llms_get_student( $user_id ); + if ( is_null( $object_id ) || ! $student ) { return; } if ( 'favorite' === $user_action ) { + // You can never mark favorite a non-free lesson of a course you're not enrolled into. + if ( 'lesson' === $object_type ) { + $lesson = llms_get_post( $object_id ); + $can_mark_favorite = $lesson && ( $student->is_enrolled( $object_id ) || $lesson->is_free() ); + if ( ! $can_mark_favorite ) { + return; + } + } - $r = llms_mark_favorite( $user_id, $object_id, $object_type ); - + llms_mark_favorite( $user_id, $object_id, $object_type ); } elseif ( 'unfavorite' === $user_action ) { - - $r = llms_mark_unfavorite( $user_id, $object_id, $object_type ); - + llms_mark_unfavorite( $user_id, $object_id, $object_type ); } echo wp_json_encode( diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 176bca85db..460f32b024 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -12,11 +12,20 @@ */ defined( 'ABSPATH' ) || exit; -global $post; - -$lesson = new LLMS_Lesson( empty( $object_id ) ? $post->ID : $object_id ); -$student = llms_get_student( get_current_user_id() ); -$total_favorites = llms_get_object_total_favorites( $lesson->get( 'id' ) ); +$lesson = null; +if ( 'lesson' === $object_type ) { + global $post; + $lesson = llms_get_post( empty( $object_id ) ? $post : $object_id ); +} + +if ( ! $lesson || ! is_a( $lesson, 'LLMS_Lesson' ) ) { + return; +} + +$total_favorites = llms_get_object_total_favorites( $lesson->get( 'id' ) ); +$student = llms_get_student( get_current_user_id() ); +$is_favorite = $student && $student->is_favorite( $lesson->get( 'id' ), 'lesson' ); +$can_mark_favorite = $lesson && ( ( $student && $student->is_enrolled( $lesson->get( 'id' ) ) ) || $lesson->is_free() ); ?>
@@ -33,13 +42,13 @@ do_action( 'llms_before_favorite_button', $lesson, $student ); ?> - + - is_favorite( $lesson->get( 'id' ), 'lesson' ) ) : ?> + From ae90e40a61bbd1d4ce65a27ca3f602037416a64b Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Thu, 2 Nov 2023 12:12:39 +0100 Subject: [PATCH 067/522] fix cs --- includes/functions/llms.functions.person.php | 46 +++++++++---------- .../llms.functions.templates.dashboard.php | 3 +- 2 files changed, 24 insertions(+), 25 deletions(-) diff --git a/includes/functions/llms.functions.person.php b/includes/functions/llms.functions.person.php index faa776281b..c6302b3257 100644 --- a/includes/functions/llms.functions.person.php +++ b/includes/functions/llms.functions.person.php @@ -23,7 +23,7 @@ * @param integer $post_id A WP_Post ID to check permissions against. If supplied, in addition to the user's role * being allowed to bypass the restrictions, the user must also have `edit_post` capabilities * for the requested post. - * @return boolean + * @return bool */ function llms_can_user_bypass_restrictions( $user = null, $post_id = null ) { @@ -58,7 +58,7 @@ function llms_can_user_bypass_restrictions( $user = null, $post_id = null ) { * * @param string $cap Capability name. * @param int $obj_id WP_Post or WP_User ID. - * @return boolean + * @return bool */ function llms_current_user_can( $cap, $obj_id = null ) { @@ -114,8 +114,8 @@ function llms_current_user_can( $cap, $obj_id = null ) { * * @since 3.13.0 * - * @param boolean $grant Whether or not the requested capability is granted to the user. - * @param int $obj_id WP_Post or WP_User ID. + * @param bool $grant Whether or not the requested capability is granted to the user. + * @param int $obj_id WP_Post or WP_User ID. */ return apply_filters( "llms_current_user_can_{$cap}", $grant, $obj_id ); @@ -132,7 +132,7 @@ function llms_current_user_can( $cap, $obj_id = null ) { * @param int $product_id WP Post ID of the Course or Membership. * @param string $trigger Optional. Only delete the student enrollment if the original enrollment trigger matches the submitted value. * Passing "any" will remove regardless of enrollment trigger. - * @return boolean Whether or not the enrollment records have been successfully removed. + * @return bool Whether or not the enrollment records have been successfully removed. */ function llms_delete_student_enrollment( $user_id, $product_id, $trigger = 'any' ) { $student = new LLMS_Student( $user_id ); @@ -156,7 +156,7 @@ function llms_disable_admin_bar( $show_admin_bar ) { * * @since Unknown * - * @param boolean $disabled Whether or not the admin bar should be disabled. + * @param bool $disabled Whether or not the admin bar should be disabled. */ if ( apply_filters( 'lifterlms_disable_admin_bar', true ) && ! ( current_user_can( 'edit_posts' ) || current_user_can( 'manage_lifterlms' ) ) ) { $show_admin_bar = false; @@ -177,7 +177,7 @@ function llms_disable_admin_bar( $show_admin_bar ) { * @param int $user_id WP User ID. * @param int $product_id WP Post ID of the Course or Membership. * @param string $trigger String describing the event that triggered the enrollment. - * @return boolean + * @return bool */ function llms_enroll_student( $user_id, $product_id, $trigger = 'unspecified' ) { $student = new LLMS_Student( $user_id ); @@ -237,9 +237,9 @@ function llms_get_minimum_password_strength_name( $strength = 'strong' ) { * @since 3.9.0 Unknown * @since 7.1.0 Added the `$autoload` parameter. * - * @param mixed $user WP_User ID, instance of WP_User, or instance of any student class extending this class. - * @param boolean $autoload If `true` and `$user` input is empty, the user will be loaded from `get_current_user_id()`. - * If `$user` is not empty then this parameter has no impact. + * @param mixed $user WP_User ID, instance of WP_User, or instance of any student class extending this class. + * @param bool $autoload If `true` and `$user` input is empty, the user will be loaded from `get_current_user_id()`. + * If `$user` is not empty then this parameter has no impact. * @return LLMS_Student|false LLMS_Student instance on success, false if user not found. */ function llms_get_student( $user = null, $autoload = true ) { @@ -284,7 +284,7 @@ function llms_get_usernames_blocklist() { * @param int $user_id WP User ID of the user. * @param int $object_id WP Post ID of a Course, Section, or Lesson. * @param int $object_type Type, either Course, Section, or Lesson. - * @return boolean Returns `true` if complete, otherwise `false`. + * @return bool Returns `true` if complete, otherwise `false`. */ function llms_is_complete( $user_id, $object_id, $object_type = 'course' ) { $s = new LLMS_Student( $user_id ); @@ -307,7 +307,7 @@ function llms_is_complete( $user_id, $object_id, $object_type = 'course' ) { * All = user must be enrolled in all $product_ids. * Any = user must be enrolled in at least one of the $product_ids. * @param bool $use_cache If true, returns cached data if available, if false will run a db query. - * @return boolean + * @return bool */ function llms_is_user_enrolled( $user_id, $product_id, $relation = 'all', $use_cache = true ) { $student = new LLMS_Student( $user_id ); @@ -327,7 +327,7 @@ function llms_is_user_enrolled( $user_id, $product_id, $relation = 'all', $use_c * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. * @param string $object_type Object type [lesson|section|course|track]. * @param string $trigger String describing the event that triggered marking the object as complete. - * @return boolean + * @return bool */ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'unspecified' ) { $student = new LLMS_Student( $user_id ); @@ -345,7 +345,7 @@ function llms_mark_complete( $user_id, $object_id, $object_type, $trigger = 'uns * @param int $object_id WP Post ID of the Lesson, Section, Track, or Course. * @param string $object_type Object type [lesson|section|course|track]. * @param string $trigger String describing the event that triggered marking the object as incomplete. - * @return boolean + * @return bool */ function llms_mark_incomplete( $user_id, $object_id, $object_type, $trigger = 'unspecified' ) { $student = new LLMS_Student( $user_id ); @@ -362,7 +362,7 @@ function llms_mark_incomplete( $user_id, $object_id, $object_type, $trigger = 'u * @param int $user_id WP User ID. * @param int $object_id WP Post ID of the object to mark/unmark as favorite. * @param string $object_type The object type, currently only 'lesson'. - * @return boolean + * @return bool */ function llms_mark_favorite( $user_id, $object_id, $object_type ) { $student = new LLMS_Student( $user_id ); @@ -379,7 +379,7 @@ function llms_mark_favorite( $user_id, $object_id, $object_type ) { * @param int $user_id WP User ID. * @param int $object_id WP Post ID of the object to mark/unmark as favorite. * @param string $object_type The object type, currently only 'lesson'. - * @return boolean + * @return bool */ function llms_mark_unfavorite( $user_id, $object_id, $object_type ) { $student = new LLMS_Student( $user_id ); @@ -433,8 +433,8 @@ function llms_parse_password_reset_cookie() { * @since 5.0.0 Use `LLMS_Form_Handler()` for registration. * * @param array $data Array of registration data. - * @param string $screen The screen to be used for the validation template, accepts "registration" or "checkout" - * @param bool $signon If true, signon the newly created user + * @param string $screen The screen to be used for the validation template, accepts "registration" or "checkout". + * @param bool $signon If true, signon the newly created user. * @param array $args Additional arguments passed to the short-circuit filter. * @return int|WP_Error */ @@ -456,7 +456,7 @@ function llms_register_user( $data = array(), $screen = 'registration', $signon * * @since 5.0.0 * - * @param boolean $remember If `true` (default), the user signon will be set to "remember". + * @param bool $remember If `true` (default), the user signon will be set to "remember". * @param string $screen Current validation template, either "registration" or "checkout". * @param WP_User $user User object for the newly registered user. */ @@ -483,7 +483,7 @@ function llms_register_user( $data = array(), $screen = 'registration', $signon * @since 5.0.0 * * @param string $val Cookie value. - * @return boolean + * @return bool */ function llms_set_password_reset_cookie( $val = '' ) { @@ -521,7 +521,7 @@ function llms_set_user_login_time( $user_login, $user ) { * @param string $new_status The value to update the new status with after removal is complete. * @param string $trigger Only remove the student if the original enrollment trigger matches the submitted value. * Passing "any" will remove regardless of enrollment trigger. - * @return boolean + * @return bool */ function llms_unenroll_student( $user_id, $product_id, $new_status = 'expired', $trigger = 'any' ) { $student = new LLMS_Student( $user_id ); @@ -555,8 +555,8 @@ function llms_update_user( $data = array(), $location = 'account', $args = array * @param array $data Array of user data. * @param string $location (Optional) screen to perform validations for, accepts "account" or "checkout". Default value: 'checkout' * @param array $args Additional arguments passed to the short-circuit filter. - * @return boolean|WP_Error Returns `true` if the user data passes validation, otherwise returns an error object describing - * the validation issues. + * @return bool|WP_Error Returns `true` if the user data passes validation, otherwise returns an error object describing + * the validation issues. */ function llms_validate_user( $data = array(), $location = 'checkout', $args = array() ) { $args['validate_only'] = true; diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index f10f07885b..5ef9fb330a 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -608,10 +608,9 @@ function lifterlms_template_student_dashboard_my_courses( $preview = false ) { * * @since [version] * - * @param bool $preview Optional. If true, outputs a short list of favorites. Default `false`. * @return void */ - function llms_template_student_dashboard_my_favorites( $preview = false ) { + function llms_template_student_dashboard_my_favorites() { $student = llms_get_student(); From 4cef5735918cacfb862822cb663182c6608f6279 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Thu, 2 Nov 2023 12:16:29 +0100 Subject: [PATCH 068/522] No need to add the My Favorites section on the main dashboard page --- .../functions/llms.functions.templates.dashboard.php | 11 +---------- includes/llms.template.hooks.php | 1 - 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 5ef9fb330a..304d4028e7 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -618,14 +618,6 @@ function llms_template_student_dashboard_my_favorites() { return; } - $more = false; - if ( $preview && LLMS_Student_Dashboard::is_endpoint_enabled( 'view-favorites' ) ) { - $more = array( - 'url' => llms_get_endpoint_url( 'view-favorites', '', llms_get_page_url( 'myaccount' ) ), - 'text' => esc_html__( 'View All My Favorites', 'lifterlms' ), - ); - } - ob_start(); llms_template_my_favorites_loop( $student ); @@ -635,8 +627,7 @@ function llms_template_student_dashboard_my_favorites() { 'action' => 'my_favorites', 'slug' => 'llms-my-favorites', 'title' => $preview ? esc_html__( 'My Favorites', 'lifterlms' ) : '', - 'content' => ob_get_clean(), - 'more' => $more, + 'content' => ob_get_clean() ) ); diff --git a/includes/llms.template.hooks.php b/includes/llms.template.hooks.php index b50cf32be8..5c84d383b9 100644 --- a/includes/llms.template.hooks.php +++ b/includes/llms.template.hooks.php @@ -182,7 +182,6 @@ add_action( 'llms_achievement_content', 'llms_the_achievement', 10 ); add_action( 'llms_certificate_preview', 'llms_the_certificate_preview', 10 ); add_action( 'lifterlms_student_dashboard_index', 'lifterlms_template_student_dashboard_my_memberships', 40 ); -add_action( 'lifterlms_student_dashboard_index', 'llms_template_student_dashboard_my_favorites', 50 ); add_action( 'llms_my_grades_course_table', 'lifterlms_template_student_dashboard_my_grades_table', 10, 2 ); From 623045a071929c8b0805a3e47365e688b3f1ad2e Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Thu, 2 Nov 2023 12:20:00 +0100 Subject: [PATCH 069/522] fix cs --- includes/functions/llms.functions.templates.dashboard.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index 304d4028e7..d32ee4a54a 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -627,7 +627,7 @@ function llms_template_student_dashboard_my_favorites() { 'action' => 'my_favorites', 'slug' => 'llms-my-favorites', 'title' => $preview ? esc_html__( 'My Favorites', 'lifterlms' ) : '', - 'content' => ob_get_clean() + 'content' => ob_get_clean(), ) ); From bc7a22130031dad2d76cb9dded1ec2f58d26f7a9 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Thu, 2 Nov 2023 12:28:41 +0100 Subject: [PATCH 070/522] favorites feature enabled for new users, disabled for old users --- .../settings/class.llms.settings.courses.php | 2 +- .../updates/llms-functions-updates-6100.php | 2 +- .../updates/llms-functions-updates-750.php | 49 +++++++++++++++++++ includes/schemas/llms-db-updates.php | 10 +++- 4 files changed, 60 insertions(+), 3 deletions(-) create mode 100644 includes/functions/updates/llms-functions-updates-750.php diff --git a/includes/admin/settings/class.llms.settings.courses.php b/includes/admin/settings/class.llms.settings.courses.php index a3220a3502..a748c8a428 100644 --- a/includes/admin/settings/class.llms.settings.courses.php +++ b/includes/admin/settings/class.llms.settings.courses.php @@ -82,7 +82,7 @@ public function get_settings() { 'title' => __( 'Lesson Favorites', 'lifterlms' ), 'desc' => __( 'Enabling this setting allows students to mark a lesson as "favorite".', 'lifterlms' ), 'id' => 'lifterlms_favorites', - 'default' => 'no', + 'default' => 'yes', 'type' => 'checkbox', ), diff --git a/includes/functions/updates/llms-functions-updates-6100.php b/includes/functions/updates/llms-functions-updates-6100.php index a16226a363..1b32ad1853 100644 --- a/includes/functions/updates/llms-functions-updates-6100.php +++ b/includes/functions/updates/llms-functions-updates-6100.php @@ -98,7 +98,7 @@ function migrate_spanish_users() { * * @since 6.10.0 * - * @return fasle. + * @return false. */ function update_db_version() { \LLMS_Install::update_db_version( _get_db_version() ); diff --git a/includes/functions/updates/llms-functions-updates-750.php b/includes/functions/updates/llms-functions-updates-750.php new file mode 100644 index 0000000000..91c9eea34f --- /dev/null +++ b/includes/functions/updates/llms-functions-updates-750.php @@ -0,0 +1,49 @@ + array( + 'type' => 'auto', + 'namespace' => true, + 'updates' => array( + 'favorites_feature_bc', + 'update_db_version', + ), + ), ); From cbc3ec5b7b23446fd931840d68742749c9c13da0 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Thu, 2 Nov 2023 12:47:07 +0100 Subject: [PATCH 071/522] Apply suggestions from code review Co-authored-by: Akash <18614782+actuallyakash@users.noreply.github.com> --- .changelogs/feature_favorite-5.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.changelogs/feature_favorite-5.yml b/.changelogs/feature_favorite-5.yml index a914bb2c31..371a23c35a 100644 --- a/.changelogs/feature_favorite-5.yml +++ b/.changelogs/feature_favorite-5.yml @@ -1,3 +1,3 @@ significance: patch type: dev -entry: Added function `llms_template_syllabus_syllabus_lesson_preview`. +entry: Added function `llms_template_syllabus_favorite_lesson_preview`. From f777f60718de33d84f2757a5c721787f43988653 Mon Sep 17 00:00:00 2001 From: Rocco Aliberti Date: Thu, 2 Nov 2023 13:02:36 +0100 Subject: [PATCH 072/522] fix my favorites templating --- .../llms.functions.templates.dashboard.php | 5 +---- templates/myaccount/my-favorites.php | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 4 deletions(-) create mode 100644 templates/myaccount/my-favorites.php diff --git a/includes/functions/llms.functions.templates.dashboard.php b/includes/functions/llms.functions.templates.dashboard.php index d32ee4a54a..07c3d9e289 100644 --- a/includes/functions/llms.functions.templates.dashboard.php +++ b/includes/functions/llms.functions.templates.dashboard.php @@ -622,11 +622,8 @@ function llms_template_student_dashboard_my_favorites() { llms_template_my_favorites_loop( $student ); llms_get_template( - 'myaccount/dashboard-section.php', + 'myaccount/my-favorites.php', array( - 'action' => 'my_favorites', - 'slug' => 'llms-my-favorites', - 'title' => $preview ? esc_html__( 'My Favorites', 'lifterlms' ) : '', 'content' => ob_get_clean(), ) ); diff --git a/templates/myaccount/my-favorites.php b/templates/myaccount/my-favorites.php new file mode 100644 index 0000000000..5300e2851b --- /dev/null +++ b/templates/myaccount/my-favorites.php @@ -0,0 +1,17 @@ + + +
+ +
+ From 8e375ebf1c6e80156a5e46b8026bd4f68dd79394 Mon Sep 17 00:00:00 2001 From: Jason Coleman Date: Fri, 3 Nov 2023 12:44:15 -0400 Subject: [PATCH 073/522] Flushing rewrite rules on save in case favorites are added. --- includes/admin/settings/class.llms.settings.courses.php | 1 + 1 file changed, 1 insertion(+) diff --git a/includes/admin/settings/class.llms.settings.courses.php b/includes/admin/settings/class.llms.settings.courses.php index a748c8a428..63c6b0adbd 100644 --- a/includes/admin/settings/class.llms.settings.courses.php +++ b/includes/admin/settings/class.llms.settings.courses.php @@ -181,6 +181,7 @@ public function save() { public function output() { $settings = $this->get_settings(); LLMS_Admin_Settings::output_fields( $settings ); + add_action( 'shutdown', array( $this, 'flush_rewrite_rules' ) ); } } From 735e47f1d840a73141798b2e9f72a23485f9b1ad Mon Sep 17 00:00:00 2001 From: Jason Coleman Date: Fri, 3 Nov 2023 13:00:47 -0400 Subject: [PATCH 074/522] default endpoints should be my- --- includes/class.llms.student.dashboard.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/includes/class.llms.student.dashboard.php b/includes/class.llms.student.dashboard.php index ebc8ae9ab5..93a4c49e32 100644 --- a/includes/class.llms.student.dashboard.php +++ b/includes/class.llms.student.dashboard.php @@ -156,7 +156,7 @@ public static function get_tabs() { ), 'view-courses' => array( 'content' => 'lifterlms_template_student_dashboard_my_courses', - 'endpoint' => get_option( 'lifterlms_myaccount_courses_endpoint', 'view-courses' ), + 'endpoint' => get_option( 'lifterlms_myaccount_courses_endpoint', 'my-courses' ), 'paginate' => true, 'nav_item' => true, 'title' => __( 'My Courses', 'lifterlms' ), @@ -170,20 +170,20 @@ public static function get_tabs() { ), 'view-memberships' => array( 'content' => 'lifterlms_template_student_dashboard_my_memberships', - 'endpoint' => get_option( 'lifterlms_myaccount_memberships_endpoint', 'view-memberships' ), + 'endpoint' => get_option( 'lifterlms_myaccount_memberships_endpoint', 'my-memberships' ), 'nav_item' => true, 'title' => __( 'My Memberships', 'lifterlms' ), ), 'view-achievements' => array( 'content' => 'lifterlms_template_student_dashboard_my_achievements', - 'endpoint' => get_option( 'lifterlms_myaccount_achievements_endpoint', 'view-achievements' ), + 'endpoint' => get_option( 'lifterlms_myaccount_achievements_endpoint', 'my-achievements' ), 'paginate' => true, 'nav_item' => true, 'title' => __( 'My Achievements', 'lifterlms' ), ), 'view-certificates' => array( 'content' => 'lifterlms_template_student_dashboard_my_certificates', - 'endpoint' => get_option( 'lifterlms_myaccount_certificates_endpoint', 'view-certificates' ), + 'endpoint' => get_option( 'lifterlms_myaccount_certificates_endpoint', 'my-certificates' ), 'paginate' => true, 'nav_item' => true, 'title' => __( 'My Certificates', 'lifterlms' ), @@ -228,7 +228,7 @@ public static function get_tabs() { 'view-favorites', array( 'content' => 'llms_template_student_dashboard_my_favorites', - 'endpoint' => get_option( 'lifterlms_myaccount_favorites_endpoint', 'view-favorites' ), + 'endpoint' => get_option( 'lifterlms_myaccount_favorites_endpoint', 'my-favorites' ), 'paginate' => true, 'nav_item' => true, 'title' => __( 'My Favorites', 'lifterlms' ), From 413b580833f21824a44259a66376588529c2a8a8 Mon Sep 17 00:00:00 2001 From: Bagus Date: Sat, 4 Nov 2023 13:29:39 +0700 Subject: [PATCH 075/522] update documentation on get_course() and get_lesson() functions --- includes/functions/llms.functions.course.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/functions/llms.functions.course.php b/includes/functions/llms.functions.course.php index f987c74f24..ad7ab17f6a 100644 --- a/includes/functions/llms.functions.course.php +++ b/includes/functions/llms.functions.course.php @@ -18,7 +18,7 @@ * * @param WP_Post|int|false $the_course Course post object or id. If `false` uses the global `$post` object. * @param array $args Arguments to pass to the LLMS_Course Constructor. - * @return array + * @return LLMS_Course */ function get_course( $the_course = false, $args = array() ) { @@ -32,14 +32,14 @@ function get_course( $the_course = false, $args = array() ) { } /** - * Get Product + * Get lesson object * * @since Unknown * @since 3.37.13 Use `LLMS_Lesson` in favor of the deprecated `LLMS_Course_Factory::get_lesson()` method. * * @param WP_Post|int|false $the_lesson Lesson post object or id. If `false` uses the global `$post` object. * @param array $args Arguments to pass to the LLMS_Lesson Constructor. - * @return LLMS_Product + * @return LLMS_Lesson */ function get_lesson( $the_lesson = false, $args = array() ) { From c76f11545b098192aca1612dd3c1c7a8b71caa22 Mon Sep 17 00:00:00 2001 From: Kim Coleman Date: Sun, 5 Nov 2023 09:20:35 -0500 Subject: [PATCH 076/522] Adding aria labels and titles to icon for accessibility --- templates/course/favorite.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/course/favorite.php b/templates/course/favorite.php index 460f32b024..257ddfdce0 100644 --- a/templates/course/favorite.php +++ b/templates/course/favorite.php @@ -50,17 +50,17 @@ - + - + - + From 2538a186e4a1e319a4ac16c03ae1a17a36067834 Mon Sep 17 00:00:00 2001 From: Kim Coleman Date: Sun, 5 Nov 2023 09:21:39 -0500 Subject: [PATCH 077/522] Updating favorites styles --- assets/scss/frontend/_main.scss | 29 +++++++++++++++-------------- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/assets/scss/frontend/_main.scss b/assets/scss/frontend/_main.scss index c956ae043c..eca058c72f 100644 --- a/assets/scss/frontend/_main.scss +++ b/assets/scss/frontend/_main.scss @@ -475,19 +475,6 @@ svg .llms-animated-circle { } // Favorites. -.llms-has-favorite .llms-parent-course-link { - display: inline; - - + .llms-favorite-wrapper { - display: inline; - float: right; - - + .llms-video-wrapper { - margin-top: 10px; - } - } -} - .llms-favorite-wrapper { cursor: pointer; @@ -496,6 +483,20 @@ svg .llms-animated-circle { } } -.llms-syllabus-wrapper .llms-favorite-wrapper { +.llms-has-favorite .llms-parent-course-link { + display: inline-block; + margin-bottom: 20px; + + + .llms-favorite-wrapper { + float: right; + margin: 0; + } +} + +.llms-syllabus-wrapper .llms-has-favorite { text-align: left; + + .llms-favorite-wrapper { + display: inline-block; + } } From 45420999c76e2ac8e055e1bcdbb86cf52c55279b Mon Sep 17 00:00:00 2001 From: Kim Coleman Date: Sun, 5 Nov 2023 11:40:55 -0500 Subject: [PATCH 078/522] Update to only show the LifterLMS-authored Add Ons on the All section of the Addons and more screen. --- .changelogs/only-lifterlms-add-ons-in-all.yml | 3 +++ includes/admin/class.llms.admin.addons.php | 27 ++++++++++++++++++- 2 files changed, 29 insertions(+), 1 deletion(-) create mode 100644 .changelogs/only-lifterlms-add-ons-in-all.yml diff --git a/.changelogs/only-lifterlms-add-ons-in-all.yml b/.changelogs/only-lifterlms-add-ons-in-all.yml new file mode 100644 index 0000000000..fa4b8ae034 --- /dev/null +++ b/.changelogs/only-lifterlms-add-ons-in-all.yml @@ -0,0 +1,3 @@ +significance: patch +type: fixed +entry: Only show LifterLMS-authored Addons in All section. diff --git a/includes/admin/class.llms.admin.addons.php b/includes/admin/class.llms.admin.addons.php index 0b466dc4e3..0deb13d8b6 100644 --- a/includes/admin/class.llms.admin.addons.php +++ b/includes/admin/class.llms.admin.addons.php @@ -68,7 +68,7 @@ private function get_current_section_content() { if ( ! $content ) { if ( 'all' === $sec ) { - $content = $this->data['items']; + $content = $this->get_all(); } elseif ( 'featured' === $sec ) { $content = $this->get_features(); } else { @@ -110,6 +110,31 @@ private function get_data() { } + /** + * Retrieve a list of addons for use on the All section + * + * @return array + * @since [version] + * @version [version] + */ + private function get_all() { + + $all = array(); + + $addons = $this->data['items']; + + foreach ( $addons as $addon ) { + // Exclude third-party Addons from the All section. + if ( in_array( 'third-party', array_keys( $addon['categories'] ), true ) ) { + continue; + } + $all[] = $addon; + } + + return $all; + + } + /** * Retrieve a list of 'featured' addons for use on the general settings screen * Excludes already available products from current site's activations From 1374729acc4bc0a702203db50b4e0954e4d3dd50 Mon Sep 17 00:00:00 2001 From: Jason Coleman Date: Sun, 5 Nov 2023 17:37:53 -0500 Subject: [PATCH 079/522] build for version 7.5 --- ...ateway-can-process-access-plan-logic-1.yml | 5 - ...ateway-can-process-access-plan-logic-2.yml | 4 - ...-gateway-can-process-access-plan-logic.yml | 5 - .changelogs/blocks-2.5.2.yml | 4 - .changelogs/dev.yml | 6 - .../export-possible-security-issue.yml | 6 - .changelogs/feature_favorite-1.yml | 3 - .changelogs/feature_favorite-2.yml | 4 - .changelogs/feature_favorite-3.yml | 4 - .changelogs/feature_favorite-4.yml | 4 - .changelogs/feature_favorite-5.yml | 3 - .changelogs/feature_favorite.yml | 3 - .changelogs/function-name-correction.yml | 6 - .changelogs/issue_2511-1.yml | 5 - .changelogs/issue_2511.yml | 5 - .changelogs/issue_2552.yml | 7 - .changelogs/issues_2434.yml | 6 - .changelogs/only-lifterlms-add-ons-in-all.yml | 3 - .changelogs/php82-1.yml | 3 - .changelogs/php82-2.yml | 5 - .changelogs/php82.yml | 4 - .changelogs/rest-beta-29.yml | 4 - .changelogs/update-action-scheduler.yml | 4 - CHANGELOG.md | 55 + assets/css/lifterlms-rtl.css | 23 + assets/css/lifterlms-rtl.min.css | 2 +- assets/css/lifterlms.css | 23 + assets/css/lifterlms.min.css | 2 +- assets/js/builder/Models/Quiz.js | 4 +- assets/js/llms-builder.js | 13 +- assets/js/llms-builder.min.js | 2 +- assets/js/llms-favorites.js | 8 +- assets/js/llms-favorites.min.js | 2 + assets/maps/css/lifterlms.css.map | 2 +- assets/maps/css/lifterlms.min.css.map | 2 +- assets/maps/js/llms-builder.js.map | 2 +- assets/maps/js/llms-builder.min.js.map | 2 +- class-lifterlms.php | 2 +- .../abstracts/abstract.llms.admin.metabox.php | 2 +- .../abstract.llms.payment.gateway.php | 6 +- .../llms.abstract.exportable.admin.table.php | 4 +- .../class-llms-admin-export-download.php | 4 +- includes/admin/class.llms.admin.addons.php | 4 +- .../settings/class.llms.settings.accounts.php | 4 +- .../settings/class.llms.settings.courses.php | 4 +- includes/admin/views/addons/addon-item.php | 4 +- includes/assets/llms-assets-scripts.php | 4 +- includes/class-llms-block-templates.php | 4 +- includes/class.llms.ajax.php | 6 +- includes/class.llms.frontend.assets.php | 4 +- includes/class.llms.l10n.js.php | 6 +- includes/class.llms.query.php | 4 +- includes/class.llms.query.user.postmeta.php | 4 +- includes/class.llms.student.dashboard.php | 4 +- .../class.llms.controller.orders.php | 6 +- .../functions/llms.functions.favorite.php | 10 +- includes/functions/llms.functions.order.php | 4 +- includes/functions/llms.functions.person.php | 6 +- .../llms.functions.templates.dashboard.php | 6 +- .../llms.functions.templates.loop.php | 4 +- .../updates/llms-functions-updates-750.php | 8 +- includes/llms.functions.core.php | 2 +- includes/llms.template.functions.php | 6 +- includes/llms.template.hooks.php | 6 +- includes/models/model.llms.add-on.php | 4 +- includes/models/model.llms.student.php | 26 +- includes/schemas/llms-db-updates.php | 2 +- .../class.llms.shortcode.favorites.php | 10 +- includes/shortcodes/class.llms.shortcodes.php | 4 +- languages/lifterlms.pot | 448 ++-- lifterlms.php | 2 +- package-lock.json | 2248 ++--------------- package.json | 2 +- readme.txt | 130 +- templates/checkout/form-gateways.php | 6 +- templates/checkout/form-switch-source.php | 2 +- templates/course/favorite.php | 6 +- templates/course/lesson-count.php | 4 +- templates/course/lesson-preview.php | 8 +- templates/myaccount/dashboard.php | 4 +- templates/myaccount/my-favorites.php | 4 +- .../unit-tests/class-llms-test-post-types.php | 4 +- .../class-llms-test-functions-template.php | 18 +- .../processors/class-llms-test-processors.php | 2 +- 84 files changed, 825 insertions(+), 2482 deletions(-) delete mode 100644 .changelogs/add-gateway-can-process-access-plan-logic-1.yml delete mode 100644 .changelogs/add-gateway-can-process-access-plan-logic-2.yml delete mode 100644 .changelogs/add-gateway-can-process-access-plan-logic.yml delete mode 100644 .changelogs/blocks-2.5.2.yml delete mode 100644 .changelogs/dev.yml delete mode 100644 .changelogs/export-possible-security-issue.yml delete mode 100644 .changelogs/feature_favorite-1.yml delete mode 100644 .changelogs/feature_favorite-2.yml delete mode 100644 .changelogs/feature_favorite-3.yml delete mode 100644 .changelogs/feature_favorite-4.yml delete mode 100644 .changelogs/feature_favorite-5.yml delete mode 100644 .changelogs/feature_favorite.yml delete mode 100644 .changelogs/function-name-correction.yml delete mode 100644 .changelogs/issue_2511-1.yml delete mode 100644 .changelogs/issue_2511.yml delete mode 100644 .changelogs/issue_2552.yml delete mode 100644 .changelogs/issues_2434.yml delete mode 100644 .changelogs/only-lifterlms-add-ons-in-all.yml delete mode 100644 .changelogs/php82-1.yml delete mode 100644 .changelogs/php82-2.yml delete mode 100644 .changelogs/php82.yml delete mode 100644 .changelogs/rest-beta-29.yml delete mode 100644 .changelogs/update-action-scheduler.yml create mode 100644 assets/js/llms-favorites.min.js diff --git a/.changelogs/add-gateway-can-process-access-plan-logic-1.yml b/.changelogs/add-gateway-can-process-access-plan-logic-1.yml deleted file mode 100644 index 170a6d34c2..0000000000 --- a/.changelogs/add-gateway-can-process-access-plan-logic-1.yml +++ /dev/null @@ -1,5 +0,0 @@ -significance: minor -type: dev -entry: Added `LLMS_Payment_Gateway::can_process_access_plan()` method to determine if an - access plan can be processed by the gateway. Also added the filter hook - `llms_can_gateway_process_access_plan` to filter its result. diff --git a/.changelogs/add-gateway-can-process-access-plan-logic-2.yml b/.changelogs/add-gateway-can-process-access-plan-logic-2.yml deleted file mode 100644 index c44b318cf7..0000000000 --- a/.changelogs/add-gateway-can-process-access-plan-logic-2.yml +++ /dev/null @@ -1,4 +0,0 @@ -significance: minor -type: dev -entry: Added a check on whether the gateway can process a specific plan when - purchasing a plan, or switching the payment gateway of a recurring payment. diff --git a/.changelogs/add-gateway-can-process-access-plan-logic.yml b/.changelogs/add-gateway-can-process-access-plan-logic.yml deleted file mode 100644 index bbdd551f1f..0000000000 --- a/.changelogs/add-gateway-can-process-access-plan-logic.yml +++ /dev/null @@ -1,5 +0,0 @@ -significance: minor -type: dev -entry: Added action hook `llms_checkout_form_gateway_cant_process_plan` fired on - the checkout form gateways section, when a gateway cannot process a specific - plan. diff --git a/.changelogs/blocks-2.5.2.yml b/.changelogs/blocks-2.5.2.yml deleted file mode 100644 index 9c812cd44e..0000000000 --- a/.changelogs/blocks-2.5.2.yml +++ /dev/null @@ -1,4 +0,0 @@ -significance: patch -type: changed -entry: Updates LifterLMS Blocks to - [v2.5.2](https://make.lifterlms.com/2023/11/01/lifterlms-blocks-version-2-5-2/). diff --git a/.changelogs/dev.yml b/.changelogs/dev.yml deleted file mode 100644 index 454ef6a088..0000000000 --- a/.changelogs/dev.yml +++ /dev/null @@ -1,6 +0,0 @@ -significance: patch -type: dev -entry: Added new filter hook - `llms_unschedule_recurring_payment_on_access_pan_expiration` to control - whether or not the recurring payments fo an order need to be - unscheduled when the related access plan expires (`true` by default). diff --git a/.changelogs/export-possible-security-issue.yml b/.changelogs/export-possible-security-issue.yml deleted file mode 100644 index a7dfe5b629..0000000000 --- a/.changelogs/export-possible-security-issue.yml +++ /dev/null @@ -1,6 +0,0 @@ -significance: patch -type: security -attributions: - - "[Huseyin Tintas (stif)](https://linkedin.com/in/huseyintintas)" -entry: "Improved security when exporting a reporting table: make sure to avoid - path traversals." diff --git a/.changelogs/feature_favorite-1.yml b/.changelogs/feature_favorite-1.yml deleted file mode 100644 index 8f8159c56c..0000000000 --- a/.changelogs/feature_favorite-1.yml +++ /dev/null @@ -1,3 +0,0 @@ -significance: minor -type: dev -entry: Added 'favorites' in User postmeta for getting all user's favorites. diff --git a/.changelogs/feature_favorite-2.yml b/.changelogs/feature_favorite-2.yml deleted file mode 100644 index bbaf6927ef..0000000000 --- a/.changelogs/feature_favorite-2.yml +++ /dev/null @@ -1,4 +0,0 @@ -significance: minor -type: dev -entry: Added filter `llms_course_syllabus_lesson_favorite_visibility` for - disabling favorites in syllabus view. diff --git a/.changelogs/feature_favorite-3.yml b/.changelogs/feature_favorite-3.yml deleted file mode 100644 index ee9fdfd87c..0000000000 --- a/.changelogs/feature_favorite-3.yml +++ /dev/null @@ -1,4 +0,0 @@ -significance: minor -type: dev -entry: Added filter `llms_is_$object_type_favorite` to change object's (lesson, - student, course) favorite boolean value. diff --git a/.changelogs/feature_favorite-4.yml b/.changelogs/feature_favorite-4.yml deleted file mode 100644 index f61c17c96b..0000000000 --- a/.changelogs/feature_favorite-4.yml +++ /dev/null @@ -1,4 +0,0 @@ -significance: patch -type: dev -entry: Added `llms_lesson_preview_before_title` and - `llms_lesson_preview_after_title` action hooks. diff --git a/.changelogs/feature_favorite-5.yml b/.changelogs/feature_favorite-5.yml deleted file mode 100644 index 371a23c35a..0000000000 --- a/.changelogs/feature_favorite-5.yml +++ /dev/null @@ -1,3 +0,0 @@ -significance: patch -type: dev -entry: Added function `llms_template_syllabus_favorite_lesson_preview`. diff --git a/.changelogs/feature_favorite.yml b/.changelogs/feature_favorite.yml deleted file mode 100644 index 55f9764807..0000000000 --- a/.changelogs/feature_favorite.yml +++ /dev/null @@ -1,3 +0,0 @@ -significance: minor -type: dev -entry: Added filter `llms_favorites_enabled` to enable/disable Favorites feature. diff --git a/.changelogs/function-name-correction.yml b/.changelogs/function-name-correction.yml deleted file mode 100644 index f7e12a448b..0000000000 --- a/.changelogs/function-name-correction.yml +++ /dev/null @@ -1,6 +0,0 @@ -significance: patch -type: fixed -links: - - "#2550" -entry: Fixed checking for the wrong function name when - defining the pluggable function `lifterlms_student_dashboard`. diff --git a/.changelogs/issue_2511-1.yml b/.changelogs/issue_2511-1.yml deleted file mode 100644 index d000893e15..0000000000 --- a/.changelogs/issue_2511-1.yml +++ /dev/null @@ -1,5 +0,0 @@ -significance: patch -type: added -links: - - "#2511" -entry: Added `LLMS_Add_On::get_image()` method to get the addon and author image. diff --git a/.changelogs/issue_2511.yml b/.changelogs/issue_2511.yml deleted file mode 100644 index 2286b4048f..0000000000 --- a/.changelogs/issue_2511.yml +++ /dev/null @@ -1,5 +0,0 @@ -significance: patch -type: changed -links: - - "#2511" -entry: Bundled Add-ons & More Banners/Author Images in Core LifterLMS. diff --git a/.changelogs/issue_2552.yml b/.changelogs/issue_2552.yml deleted file mode 100644 index a0914d7976..0000000000 --- a/.changelogs/issue_2552.yml +++ /dev/null @@ -1,7 +0,0 @@ -significance: patch -type: dev -links: - - "#2552" -attributions: - - "@AlexVCS" -entry: Removed references to the unused quiz's property `random_answers`. diff --git a/.changelogs/issues_2434.yml b/.changelogs/issues_2434.yml deleted file mode 100644 index 95aee54a5e..0000000000 --- a/.changelogs/issues_2434.yml +++ /dev/null @@ -1,6 +0,0 @@ -significance: minor -type: added -links: - - "#2434" -entry: Added a paragraph to show Number of lessons in a course at Course Catalog - and My Courses. diff --git a/.changelogs/only-lifterlms-add-ons-in-all.yml b/.changelogs/only-lifterlms-add-ons-in-all.yml deleted file mode 100644 index fa4b8ae034..0000000000 --- a/.changelogs/only-lifterlms-add-ons-in-all.yml +++ /dev/null @@ -1,3 +0,0 @@ -significance: patch -type: fixed -entry: Only show LifterLMS-authored Addons in All section. diff --git a/.changelogs/php82-1.yml b/.changelogs/php82-1.yml deleted file mode 100644 index dab24d171c..0000000000 --- a/.changelogs/php82-1.yml +++ /dev/null @@ -1,3 +0,0 @@ -significance: patch -type: dev -entry: Improved some unit tests compatibility with PHP 8.2. diff --git a/.changelogs/php82-2.yml b/.changelogs/php82-2.yml deleted file mode 100644 index 0e37eb5326..0000000000 --- a/.changelogs/php82-2.yml +++ /dev/null @@ -1,5 +0,0 @@ -significance: patch -type: fixed -entry: Improved compatibility with WordPress 6.4 by using - `traverse_and_serialize_blocks` in place of the deprecated - `_inject_theme_attribute_in_block_template_content`. diff --git a/.changelogs/php82.yml b/.changelogs/php82.yml deleted file mode 100644 index 1fcbb1f86e..0000000000 --- a/.changelogs/php82.yml +++ /dev/null @@ -1,4 +0,0 @@ -significance: patch -type: fixed -entry: "PHP 8.2 compatibility fix: Fixed creation of dynamic property - `LLMS_Meta_Box_Access::$_saved`." diff --git a/.changelogs/rest-beta-29.yml b/.changelogs/rest-beta-29.yml deleted file mode 100644 index c83792ad5a..0000000000 --- a/.changelogs/rest-beta-29.yml +++ /dev/null @@ -1,4 +0,0 @@ -significance: patch -type: changed -entry: Updates LifterLMS Rest to - [v1.0.0-beta.29](https://make.lifterlms.com/2023/10/24/lifterlms-rest-api-version-1-0-0-beta-29/). diff --git a/.changelogs/update-action-scheduler.yml b/.changelogs/update-action-scheduler.yml deleted file mode 100644 index 63ba618d5d..0000000000 --- a/.changelogs/update-action-scheduler.yml +++ /dev/null @@ -1,4 +0,0 @@ -significance: patch -type: changed -entry: Update Action Scheduler to version 3.5.4. To improve compatibility - with PHP 8.2. diff --git a/CHANGELOG.md b/CHANGELOG.md index 336af0cb1d..4affc28794 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,61 @@ LifterLMS Changelog =================== +v7.5.0 - 2023-11-05 +------------------- + +##### New Features + ++ Added `LLMS_Add_On::get_image()` method to get the addon and author image. [#2511](https://github.com/gocodebox/lifterlms/issues/2511) ++ Added a paragraph to show Number of lessons in a course at Course Catalog and My Courses. [#2434](https://github.com/gocodebox/lifterlms/issues/2434) + +##### Updates and Enhancements + ++ Updates LifterLMS Blocks to [v2.5.2](https://make.lifterlms.com/2023/11/01/lifterlms-blocks-version-2-5-2/). ++ Bundled Add-ons & More Banners/Author Images in Core LifterLMS. [#2511](https://github.com/gocodebox/lifterlms/issues/2511) ++ Updates LifterLMS Rest to [v1.0.0-beta.29](https://make.lifterlms.com/2023/10/24/lifterlms-rest-api-version-1-0-0-beta-29/). ++ Update Action Scheduler to version 3.5.4. To improve compatibility with PHP 8.2. + +##### Bug Fixes + ++ Fixed checking for the wrong function name when defining the pluggable function `lifterlms_student_dashboard`. [#2550](https://github.com/gocodebox/lifterlms/issues/2550) ++ Only show LifterLMS-authored Addons in All section. ++ Improved compatibility with WordPress 6.4 by using `traverse_and_serialize_blocks` in place of the deprecated `_inject_theme_attribute_in_block_template_content`. ++ PHP 8.2 compatibility fix: Fixed creation of dynamic property `LLMS_Meta_Box_Access::$_saved`. + +##### Developer Notes + ++ Added `LLMS_Payment_Gateway::can_process_access_plan()` method to determine if an access plan can be processed by the gateway. Also added the filter hook `llms_can_gateway_process_access_plan` to filter its result. ++ Added a check on whether the gateway can process a specific plan when purchasing a plan, or switching the payment gateway of a recurring payment. ++ Added action hook `llms_checkout_form_gateway_cant_process_plan` fired on the checkout form gateways section, when a gateway cannot process a specific plan. ++ Added new filter hook `llms_unschedule_recurring_payment_on_access_pan_expiration` to control whether or not the recurring payments fo an order need to be unscheduled when the related access plan expires (`true` by default). ++ Added 'favorites' in User postmeta for getting all user's favorites. ++ Added filter `llms_course_syllabus_lesson_favorite_visibility` for disabling favorites in syllabus view. ++ Added filter `llms_is_$object_type_favorite` to change object's (lesson, student, course) favorite boolean value. ++ Added `llms_lesson_preview_before_title` and `llms_lesson_preview_after_title` action hooks. ++ Added function `llms_template_syllabus_favorite_lesson_preview`. ++ Added filter `llms_favorites_enabled` to enable/disable Favorites feature. ++ Removed references to the unused quiz's property `random_answers`. Thanks [@AlexVCS](https://github.com/AlexVCS)! [#2552](https://github.com/gocodebox/lifterlms/issues/2552) ++ Improved some unit tests compatibility with PHP 8.2. + +##### Security Fixes + ++ Improved security when exporting a reporting table: make sure to avoid path traversals. Thanks [Huseyin Tintas (stif)](https://linkedin.com/in/huseyintintas)! + +##### Updated Templates + ++ [templates/checkout/form-gateways.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/checkout/form-gateways.php) ++ [templates/checkout/form-switch-source.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/checkout/form-switch-source.php) ++ [templates/content-single-lesson-before.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/content-single-lesson-before.php) ++ [templates/course/favorite.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/course/favorite.php) ++ [templates/course/length.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/course/length.php) ++ [templates/course/lesson-count.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/course/lesson-count.php) ++ [templates/course/lesson-preview.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/course/lesson-preview.php) ++ [templates/loop/content.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/loop/content.php) ++ [templates/myaccount/dashboard.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/myaccount/dashboard.php) ++ [templates/myaccount/my-favorites.php](https://github.com/gocodebox/lifterlms/blob/7.5.0/templates/myaccount/my-favorites.php) + + v7.4.2 - 2023-10-06 ------------------- diff --git a/assets/css/lifterlms-rtl.css b/assets/css/lifterlms-rtl.css index 0580c0054a..d3c8dd69f1 100644 --- a/assets/css/lifterlms-rtl.css +++ b/assets/css/lifterlms-rtl.css @@ -1196,6 +1196,29 @@ svg .llms-animated-circle { display: inline-block; } +.llms-favorite-wrapper { + cursor: pointer; +} +.llms-favorite-wrapper .fa-heart { + color: #EF476F; +} + +.llms-has-favorite .llms-parent-course-link { + display: inline-block; + margin-bottom: 20px; +} +.llms-has-favorite .llms-parent-course-link + .llms-favorite-wrapper { + float: left; + margin: 0; +} + +.llms-syllabus-wrapper .llms-has-favorite { + text-align: right; +} +.llms-syllabus-wrapper .llms-has-favorite .llms-favorite-wrapper { + display: inline-block; +} + .llms-loop-list { list-style: none; margin: 0 -10px; diff --git a/assets/css/lifterlms-rtl.min.css b/assets/css/lifterlms-rtl.min.css index e918331362..0983e5adfe 100644 --- a/assets/css/lifterlms-rtl.min.css +++ b/assets/css/lifterlms-rtl.min.css @@ -1,4 +1,4 @@ -.llms-pagination ul:before,.llms-pagination ul:after,.llms-student-dashboard .llms-sd-items:before,.llms-form-fields:before,.llms-checkout-cols-2:before,.llms-access-plans:before,.llms-course-navigation:before,.llms-loop-list:before,.llms-cols:before,.llms-student-dashboard .llms-sd-items:after,.llms-form-fields:after,.llms-checkout-cols-2:after,.llms-access-plans:after,.llms-course-navigation:after,.llms-loop-list:after,.llms-cols:after{content:" ";display:table}.llms-pagination ul:after,.llms-student-dashboard .llms-sd-items:after,.llms-form-fields:after,.llms-checkout-cols-2:after,.llms-access-plans:after,.llms-course-navigation:after,.llms-loop-list:after,.llms-cols:after{clear:both}.llms-cols .llms-col{width:100%}@media all and (min-width: 600px){.llms-cols [class*=llms-col-]{float:right}}.llms-flex-cols{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-flow:row wrap;flex-flow:row wrap}.llms-flex-cols [class*=llms-col]{-webkit-box-flex:0;-ms-flex:0 1 auto;flex:0 1 auto;width:100%}@media all and (min-width: 600px){.llms-cols .llms-col-1,.llms-flex-cols .llms-col-1{width:100%}.llms-cols .llms-col-2,.llms-flex-cols .llms-col-2{width:50%}.llms-cols .llms-col-3,.llms-flex-cols .llms-col-3{width:33.3333333333%}.llms-cols .llms-col-4,.llms-flex-cols .llms-col-4{width:25%}.llms-cols .llms-col-5,.llms-flex-cols .llms-col-5{width:20%}.llms-cols .llms-col-6,.llms-flex-cols .llms-col-6{width:16.6666666667%}.llms-cols .llms-col-7,.llms-flex-cols .llms-col-7{width:14.2857142857%}.llms-cols .llms-col-8,.llms-flex-cols .llms-col-8{width:12.5%}.llms-cols .llms-col-9,.llms-flex-cols .llms-col-9{width:11.1111111111%}.llms-cols .llms-col-10,.llms-flex-cols .llms-col-10{width:10%}.llms-cols .llms-col-11,.llms-flex-cols .llms-col-11{width:9.0909090909%}.llms-cols .llms-col-12,.llms-flex-cols .llms-col-12{width:8.3333333333%}}.llms-button-action,.llms-button-danger,.llms-button-primary,.llms-button-secondary{border:none;border-radius:8px;color:#fefefe;cursor:pointer;font-size:16px;font-weight:700;text-decoration:none;text-shadow:none;line-height:1;margin:0;max-width:100%;padding:12px 24px;position:relative;-webkit-transition:all .5s ease;transition:all .5s ease}.llms-button-action:disabled,.llms-button-danger:disabled,.llms-button-primary:disabled,.llms-button-secondary:disabled{opacity:.5}.llms-button-action:hover,.llms-button-action:active,.llms-button-danger:hover,.llms-button-danger:active,.llms-button-primary:hover,.llms-button-primary:active,.llms-button-secondary:hover,.llms-button-secondary:active{color:#fefefe}.llms-button-action:focus,.llms-button-danger:focus,.llms-button-primary:focus,.llms-button-secondary:focus{color:#fefefe}.llms-button-action.auto,.llms-button-danger.auto,.llms-button-primary.auto,.llms-button-secondary.auto{width:auto}.llms-button-action.full,.llms-button-danger.full,.llms-button-primary.full,.llms-button-secondary.full{display:block;text-align:center;width:100%}.llms-button-action.square,.llms-button-danger.square,.llms-button-primary.square,.llms-button-secondary.square{padding:12px}.llms-button-action.small,.llms-button-danger.small,.llms-button-primary.small,.llms-button-secondary.small{font-size:13px;padding:8px 14px}.llms-button-action.small.square,.llms-button-danger.small.square,.llms-button-primary.small.square,.llms-button-secondary.small.square{padding:8px}.llms-button-action.large,.llms-button-danger.large,.llms-button-primary.large,.llms-button-secondary.large{font-size:18px;line-height:1.2;padding:16px 32px}.llms-button-action.large.square,.llms-button-danger.large.square,.llms-button-primary.large.square,.llms-button-secondary.large.square{padding:16px}.llms-button-action.large .fa,.llms-button-danger.large .fa,.llms-button-primary.large .fa,.llms-button-secondary.large .fa{right:-7px;position:relative}.llms-button-primary{background:#2295ff}.llms-button-primary:hover,.llms-button-primary.clicked{background:#0077e4}.llms-button-primary:focus,.llms-button-primary:active{background:#4ba9ff}.llms-button-secondary{background:#e1e1e1;color:#414141}.llms-button-secondary:hover{color:#414141;background:#cdcdcd}.llms-button-secondary:focus,.llms-button-secondary:active{color:#414141;background:#ebebeb}.llms-button-action{background:#f8954f}.llms-button-action:hover,.llms-button-action.clicked{background:#f67d28}.llms-button-action:focus,.llms-button-action:active{background:#faad76}.llms-button-danger{background:#e5554e}.llms-button-danger:hover{background:#e0332a}.llms-button-danger:focus,.llms-button-danger:active{background:#e86660}.llms-button-outline{background:rgba(0,0,0,0);border:3px solid #1d2327;border-radius:8px;color:#1d2327;cursor:pointer;font-size:16px;font-weight:700;text-decoration:none;text-shadow:none;line-height:1;margin:0;max-width:100%;padding:12px 24px;position:relative;-webkit-transition:all .5s ease;transition:all .5s ease}.llms-button-outline:disabled{opacity:.5}.llms-button-outline:hover,.llms-button-outline:active{color:#1d2327}.llms-button-outline:focus{color:#1d2327}.llms-button-outline.auto{width:auto}.llms-button-outline.full{display:block;text-align:center;width:100%}.llms-button-outline.square{padding:12px}.llms-donut{background-color:#f1f1f1;background-image:none;border-radius:50%;color:#ef476f;height:200px;overflow:hidden;position:relative;width:200px}.llms-donut:before,.llms-donut:after{content:" ";display:table}.llms-donut:after{clear:both}.llms-donut svg{overflow:visible !important;pointer-events:none;width:100%}.llms-donut svg path{fill:none;stroke-width:35px;stroke:#ef476f}.llms-donut.mini{height:36px;width:36px}.llms-donut.mini .percentage{font-size:10px}.llms-donut.small{height:100px;width:100px}.llms-donut.small .percentage{font-size:18px}.llms-donut.medium{height:130px;width:130px}.llms-donut.medium .percentage{font-size:26px}.llms-donut.large{height:260px;width:260px}.llms-donut.large .percentage{font-size:48px}.llms-donut .inside{-webkit-box-align:center;-ms-flex-align:center;align-items:center;background:#fff;border-radius:50%;-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;height:80%;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;right:50%;position:absolute;text-align:center;-webkit-transform:translate(50%, -50%);transform:translate(50%, -50%);width:80%;top:50%;z-index:3}.llms-donut .percentage{line-height:1.2;font-size:34px}.llms-donut .caption{font-size:50%}.lifterlms [data-tip],.lifterlms [data-title-default],.lifterlms [data-title-active],.llms-metabox [data-tip],.llms-metabox [data-title-default],.llms-metabox [data-title-active],.llms-mb-container [data-tip],.llms-mb-container [data-title-default],.llms-mb-container [data-title-active],.llms-quiz-wrapper [data-tip],.llms-quiz-wrapper [data-title-default],.llms-quiz-wrapper [data-title-active]{position:relative}.lifterlms [data-tip].tip--top-right:before,.lifterlms [data-title-default].tip--top-right:before,.lifterlms [data-title-active].tip--top-right:before,.llms-metabox [data-tip].tip--top-right:before,.llms-metabox [data-title-default].tip--top-right:before,.llms-metabox [data-title-active].tip--top-right:before,.llms-mb-container [data-tip].tip--top-right:before,.llms-mb-container [data-title-default].tip--top-right:before,.llms-mb-container [data-title-active].tip--top-right:before,.llms-quiz-wrapper [data-tip].tip--top-right:before,.llms-quiz-wrapper [data-title-default].tip--top-right:before,.llms-quiz-wrapper [data-title-active].tip--top-right:before{bottom:100%;right:-10px}.lifterlms [data-tip].tip--top-right:hover:before,.lifterlms [data-title-default].tip--top-right:hover:before,.lifterlms [data-title-active].tip--top-right:hover:before,.llms-metabox [data-tip].tip--top-right:hover:before,.llms-metabox [data-title-default].tip--top-right:hover:before,.llms-metabox [data-title-active].tip--top-right:hover:before,.llms-mb-container [data-tip].tip--top-right:hover:before,.llms-mb-container [data-title-default].tip--top-right:hover:before,.llms-mb-container [data-title-active].tip--top-right:hover:before,.llms-quiz-wrapper [data-tip].tip--top-right:hover:before,.llms-quiz-wrapper [data-title-default].tip--top-right:hover:before,.llms-quiz-wrapper [data-title-active].tip--top-right:hover:before{bottom:calc(100% + 6px)}.lifterlms [data-tip].tip--top-right:after,.lifterlms [data-title-default].tip--top-right:after,.lifterlms [data-title-active].tip--top-right:after,.llms-metabox [data-tip].tip--top-right:after,.llms-metabox [data-title-default].tip--top-right:after,.llms-metabox [data-title-active].tip--top-right:after,.llms-mb-container [data-tip].tip--top-right:after,.llms-mb-container [data-title-default].tip--top-right:after,.llms-mb-container [data-title-active].tip--top-right:after,.llms-quiz-wrapper [data-tip].tip--top-right:after,.llms-quiz-wrapper [data-title-default].tip--top-right:after,.llms-quiz-wrapper [data-title-active].tip--top-right:after{border-top-color:#444;right:6px;top:0}.lifterlms [data-tip].tip--top-right:hover:after,.lifterlms [data-title-default].tip--top-right:hover:after,.lifterlms [data-title-active].tip--top-right:hover:after,.llms-metabox [data-tip].tip--top-right:hover:after,.llms-metabox [data-title-default].tip--top-right:hover:after,.llms-metabox [data-title-active].tip--top-right:hover:after,.llms-mb-container [data-tip].tip--top-right:hover:after,.llms-mb-container [data-title-default].tip--top-right:hover:after,.llms-mb-container [data-title-active].tip--top-right:hover:after,.llms-quiz-wrapper [data-tip].tip--top-right:hover:after,.llms-quiz-wrapper [data-title-default].tip--top-right:hover:after,.llms-quiz-wrapper [data-title-active].tip--top-right:hover:after{top:-6px}.lifterlms [data-tip].tip--top-left:before,.lifterlms [data-title-default].tip--top-left:before,.lifterlms [data-title-active].tip--top-left:before,.llms-metabox [data-tip].tip--top-left:before,.llms-metabox [data-title-default].tip--top-left:before,.llms-metabox [data-title-active].tip--top-left:before,.llms-mb-container [data-tip].tip--top-left:before,.llms-mb-container [data-title-default].tip--top-left:before,.llms-mb-container [data-title-active].tip--top-left:before,.llms-quiz-wrapper [data-tip].tip--top-left:before,.llms-quiz-wrapper [data-title-default].tip--top-left:before,.llms-quiz-wrapper [data-title-active].tip--top-left:before{bottom:100%;left:-10px}.lifterlms [data-tip].tip--top-left:hover:before,.lifterlms [data-title-default].tip--top-left:hover:before,.lifterlms [data-title-active].tip--top-left:hover:before,.llms-metabox [data-tip].tip--top-left:hover:before,.llms-metabox [data-title-default].tip--top-left:hover:before,.llms-metabox [data-title-active].tip--top-left:hover:before,.llms-mb-container [data-tip].tip--top-left:hover:before,.llms-mb-container [data-title-default].tip--top-left:hover:before,.llms-mb-container [data-title-active].tip--top-left:hover:before,.llms-quiz-wrapper [data-tip].tip--top-left:hover:before,.llms-quiz-wrapper [data-title-default].tip--top-left:hover:before,.llms-quiz-wrapper [data-title-active].tip--top-left:hover:before{bottom:calc(100% + 6px)}.lifterlms [data-tip].tip--top-left:after,.lifterlms [data-title-default].tip--top-left:after,.lifterlms [data-title-active].tip--top-left:after,.llms-metabox [data-tip].tip--top-left:after,.llms-metabox [data-title-default].tip--top-left:after,.llms-metabox [data-title-active].tip--top-left:after,.llms-mb-container [data-tip].tip--top-left:after,.llms-mb-container [data-title-default].tip--top-left:after,.llms-mb-container [data-title-active].tip--top-left:after,.llms-quiz-wrapper [data-tip].tip--top-left:after,.llms-quiz-wrapper [data-title-default].tip--top-left:after,.llms-quiz-wrapper [data-title-active].tip--top-left:after{border-top-color:#444;left:6px;top:0}.lifterlms [data-tip].tip--top-left:hover:after,.lifterlms [data-title-default].tip--top-left:hover:after,.lifterlms [data-title-active].tip--top-left:hover:after,.llms-metabox [data-tip].tip--top-left:hover:after,.llms-metabox [data-title-default].tip--top-left:hover:after,.llms-metabox [data-title-active].tip--top-left:hover:after,.llms-mb-container [data-tip].tip--top-left:hover:after,.llms-mb-container [data-title-default].tip--top-left:hover:after,.llms-mb-container [data-title-active].tip--top-left:hover:after,.llms-quiz-wrapper [data-tip].tip--top-left:hover:after,.llms-quiz-wrapper [data-title-default].tip--top-left:hover:after,.llms-quiz-wrapper [data-title-active].tip--top-left:hover:after{top:-6px}.lifterlms [data-tip].tip--bottom-left:before,.lifterlms [data-title-default].tip--bottom-left:before,.lifterlms [data-title-active].tip--bottom-left:before,.llms-metabox [data-tip].tip--bottom-left:before,.llms-metabox [data-title-default].tip--bottom-left:before,.llms-metabox [data-title-active].tip--bottom-left:before,.llms-mb-container [data-tip].tip--bottom-left:before,.llms-mb-container [data-title-default].tip--bottom-left:before,.llms-mb-container [data-title-active].tip--bottom-left:before,.llms-quiz-wrapper [data-tip].tip--bottom-left:before,.llms-quiz-wrapper [data-title-default].tip--bottom-left:before,.llms-quiz-wrapper [data-title-active].tip--bottom-left:before{top:100%;left:-10px}.lifterlms [data-tip].tip--bottom-left:hover:before,.lifterlms [data-title-default].tip--bottom-left:hover:before,.lifterlms [data-title-active].tip--bottom-left:hover:before,.llms-metabox [data-tip].tip--bottom-left:hover:before,.llms-metabox [data-title-default].tip--bottom-left:hover:before,.llms-metabox [data-title-active].tip--bottom-left:hover:before,.llms-mb-container [data-tip].tip--bottom-left:hover:before,.llms-mb-container [data-title-default].tip--bottom-left:hover:before,.llms-mb-container [data-title-active].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-tip].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-title-default].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-title-active].tip--bottom-left:hover:before{top:calc(100% + 6px)}.lifterlms [data-tip].tip--bottom-left:after,.lifterlms [data-title-default].tip--bottom-left:after,.lifterlms [data-title-active].tip--bottom-left:after,.llms-metabox [data-tip].tip--bottom-left:after,.llms-metabox [data-title-default].tip--bottom-left:after,.llms-metabox [data-title-active].tip--bottom-left:after,.llms-mb-container [data-tip].tip--bottom-left:after,.llms-mb-container [data-title-default].tip--bottom-left:after,.llms-mb-container [data-title-active].tip--bottom-left:after,.llms-quiz-wrapper [data-tip].tip--bottom-left:after,.llms-quiz-wrapper [data-title-default].tip--bottom-left:after,.llms-quiz-wrapper [data-title-active].tip--bottom-left:after{border-bottom-color:#444;left:6px;bottom:0}.lifterlms [data-tip].tip--bottom-left:hover:after,.lifterlms [data-title-default].tip--bottom-left:hover:after,.lifterlms [data-title-active].tip--bottom-left:hover:after,.llms-metabox [data-tip].tip--bottom-left:hover:after,.llms-metabox [data-title-default].tip--bottom-left:hover:after,.llms-metabox [data-title-active].tip--bottom-left:hover:after,.llms-mb-container [data-tip].tip--bottom-left:hover:after,.llms-mb-container [data-title-default].tip--bottom-left:hover:after,.llms-mb-container [data-title-active].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-tip].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-title-default].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-title-active].tip--bottom-left:hover:after{bottom:-6px}.lifterlms [data-tip].tip--bottom-right:before,.lifterlms [data-title-default].tip--bottom-right:before,.lifterlms [data-title-active].tip--bottom-right:before,.llms-metabox [data-tip].tip--bottom-right:before,.llms-metabox [data-title-default].tip--bottom-right:before,.llms-metabox [data-title-active].tip--bottom-right:before,.llms-mb-container [data-tip].tip--bottom-right:before,.llms-mb-container [data-title-default].tip--bottom-right:before,.llms-mb-container [data-title-active].tip--bottom-right:before,.llms-quiz-wrapper [data-tip].tip--bottom-right:before,.llms-quiz-wrapper [data-title-default].tip--bottom-right:before,.llms-quiz-wrapper [data-title-active].tip--bottom-right:before{top:100%;right:-10px}.lifterlms [data-tip].tip--bottom-right:hover:before,.lifterlms [data-title-default].tip--bottom-right:hover:before,.lifterlms [data-title-active].tip--bottom-right:hover:before,.llms-metabox [data-tip].tip--bottom-right:hover:before,.llms-metabox [data-title-default].tip--bottom-right:hover:before,.llms-metabox [data-title-active].tip--bottom-right:hover:before,.llms-mb-container [data-tip].tip--bottom-right:hover:before,.llms-mb-container [data-title-default].tip--bottom-right:hover:before,.llms-mb-container [data-title-active].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-tip].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-title-default].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-title-active].tip--bottom-right:hover:before{top:calc(100% + 6px)}.lifterlms [data-tip].tip--bottom-right:after,.lifterlms [data-title-default].tip--bottom-right:after,.lifterlms [data-title-active].tip--bottom-right:after,.llms-metabox [data-tip].tip--bottom-right:after,.llms-metabox [data-title-default].tip--bottom-right:after,.llms-metabox [data-title-active].tip--bottom-right:after,.llms-mb-container [data-tip].tip--bottom-right:after,.llms-mb-container [data-title-default].tip--bottom-right:after,.llms-mb-container [data-title-active].tip--bottom-right:after,.llms-quiz-wrapper [data-tip].tip--bottom-right:after,.llms-quiz-wrapper [data-title-default].tip--bottom-right:after,.llms-quiz-wrapper [data-title-active].tip--bottom-right:after{border-bottom-color:#444;right:6px;bottom:0}.lifterlms [data-tip].tip--bottom-right:hover:after,.lifterlms [data-title-default].tip--bottom-right:hover:after,.lifterlms [data-title-active].tip--bottom-right:hover:after,.llms-metabox [data-tip].tip--bottom-right:hover:after,.llms-metabox [data-title-default].tip--bottom-right:hover:after,.llms-metabox [data-title-active].tip--bottom-right:hover:after,.llms-mb-container [data-tip].tip--bottom-right:hover:after,.llms-mb-container [data-title-default].tip--bottom-right:hover:after,.llms-mb-container [data-title-active].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-tip].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-title-default].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-title-active].tip--bottom-right:hover:after{bottom:-6px}.lifterlms [data-tip]:before,.lifterlms [data-title-default]:before,.lifterlms [data-title-active]:before,.llms-metabox [data-tip]:before,.llms-metabox [data-title-default]:before,.llms-metabox [data-title-active]:before,.llms-mb-container [data-tip]:before,.llms-mb-container [data-title-default]:before,.llms-mb-container [data-title-active]:before,.llms-quiz-wrapper [data-tip]:before,.llms-quiz-wrapper [data-title-default]:before,.llms-quiz-wrapper [data-title-active]:before{background:#444;border-radius:4px;color:#fff;font-size:13px;line-height:1.2;padding:8px;max-width:300px;width:-webkit-max-content;width:-moz-max-content;width:max-content}.lifterlms [data-tip]:after,.lifterlms [data-title-default]:after,.lifterlms [data-title-active]:after,.llms-metabox [data-tip]:after,.llms-metabox [data-title-default]:after,.llms-metabox [data-title-active]:after,.llms-mb-container [data-tip]:after,.llms-mb-container [data-title-default]:after,.llms-mb-container [data-title-active]:after,.llms-quiz-wrapper [data-tip]:after,.llms-quiz-wrapper [data-title-default]:after,.llms-quiz-wrapper [data-title-active]:after{content:"";border:6px solid rgba(0,0,0,0);height:0;width:0}.lifterlms [data-tip]:before,.lifterlms [data-tip]:after,.lifterlms [data-title-default]:before,.lifterlms [data-title-default]:after,.lifterlms [data-title-active]:before,.lifterlms [data-title-active]:after,.llms-metabox [data-tip]:before,.llms-metabox [data-tip]:after,.llms-metabox [data-title-default]:before,.llms-metabox [data-title-default]:after,.llms-metabox [data-title-active]:before,.llms-metabox [data-title-active]:after,.llms-mb-container [data-tip]:before,.llms-mb-container [data-tip]:after,.llms-mb-container [data-title-default]:before,.llms-mb-container [data-title-default]:after,.llms-mb-container [data-title-active]:before,.llms-mb-container [data-title-active]:after,.llms-quiz-wrapper [data-tip]:before,.llms-quiz-wrapper [data-tip]:after,.llms-quiz-wrapper [data-title-default]:before,.llms-quiz-wrapper [data-title-default]:after,.llms-quiz-wrapper [data-title-active]:before,.llms-quiz-wrapper [data-title-active]:after{opacity:0;-webkit-transition:all .2s .1s ease;transition:all .2s .1s ease;position:absolute;pointer-events:none;visibility:hidden}.lifterlms [data-tip]:hover:before,.lifterlms [data-tip]:hover:after,.lifterlms [data-title-default]:hover:before,.lifterlms [data-title-default]:hover:after,.lifterlms [data-title-active]:hover:before,.lifterlms [data-title-active]:hover:after,.llms-metabox [data-tip]:hover:before,.llms-metabox [data-tip]:hover:after,.llms-metabox [data-title-default]:hover:before,.llms-metabox [data-title-default]:hover:after,.llms-metabox [data-title-active]:hover:before,.llms-metabox [data-title-active]:hover:after,.llms-mb-container [data-tip]:hover:before,.llms-mb-container [data-tip]:hover:after,.llms-mb-container [data-title-default]:hover:before,.llms-mb-container [data-title-default]:hover:after,.llms-mb-container [data-title-active]:hover:before,.llms-mb-container [data-title-active]:hover:after,.llms-quiz-wrapper [data-tip]:hover:before,.llms-quiz-wrapper [data-tip]:hover:after,.llms-quiz-wrapper [data-title-default]:hover:before,.llms-quiz-wrapper [data-title-default]:hover:after,.llms-quiz-wrapper [data-title-active]:hover:before,.llms-quiz-wrapper [data-title-active]:hover:after{opacity:1;-webkit-transition:all .2s .6s ease;transition:all .2s .6s ease;visibility:visible;z-index:99999999}.lifterlms [data-tip]:before,.llms-metabox [data-tip]:before,.llms-mb-container [data-tip]:before,.llms-quiz-wrapper [data-tip]:before{content:attr(data-tip)}.lifterlms [data-tip].active:before,.llms-metabox [data-tip].active:before,.llms-mb-container [data-tip].active:before,.llms-quiz-wrapper [data-tip].active:before{content:attr(data-tip-active)}.llms-membership-image{display:block;margin:0 auto}.llms-course-image{display:block;margin:0 auto;max-width:100%}.llms-featured-image{display:block;margin:0 auto}.llms-image-thumb{width:150px}.llms-video-wrapper .center-video{height:auto;max-width:100%;overflow:hidden;position:relative;padding-top:56.25%;text-align:center}.llms-video-wrapper .center-video>.wp-video,.llms-video-wrapper .center-video .fluid-width-video-wrapper,.llms-video-wrapper .center-video iframe,.llms-video-wrapper .center-video object,.llms-video-wrapper .center-video embed{height:100%;right:0;position:absolute;top:0;width:100%}.llms-video-wrapper .center-video>.wp-video{width:100% !important}.llms-video-wrapper .center-video .fluid-width-video-wrapper{padding-top:0 !important}.clear{clear:both;width:100%}.llms-featured-image{text-align:center}#main-content .llms-payment-options p{margin:0;font-size:16px}.llms-option{display:block;position:relative;margin:20px 0;padding-right:40px;font-size:16px}.llms-option label{cursor:pointer;position:static}.llms-option:first-child{margin-top:0}.llms-option:last-child{margin-bottom:0}#main-content .llms-option:last-child{margin-bottom:0}.llms-option input[type=radio]{display:block;position:absolute;top:3px;right:0;z-index:0}.llms-option input[type=radio]{display:inline-block}.llms-option input[type=radio]+label span.llms-radio{display:none}.llms-option input[type=radio]+label span.llms-radio{-webkit-appearance:none;-moz-appearance:none;appearance:none;z-index:20;position:absolute;top:0;right:-2px;display:inline-block;width:24px;height:24px;border-radius:50%;cursor:pointer;vertical-align:middle;-webkit-box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.5) 0 0 0 1px;box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.5) 0 0 0 1px;background:#efefef;background-image:radial-gradient(ellipse at center, #e5554e 0%, #e5554e 40%, #efefef 45%);background-repeat:no-repeat;-webkit-transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);transition:background-position .15s cubic-bezier(0.8, 0, 1, 1)}.llms-option input[type=radio]:checked+label span.llms-radio{-webkit-transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1)}.llms-option input[type=radio]+label span.llms-radio{background-position:-24px 0}.llms-option input[type=radio]:checked+label span.llms-radio{background-position:100% 0}.llms-option input[type=submit]{border:none;background:#e5554e;color:#fff;font-size:20px;padding:10px 0;border-radius:3px;cursor:pointer;width:100%}.llms-styled-text{padding:14px 0}.llms-notice-box{border-radius:3px;z-index:10;margin:10px 0;padding:15px 20px;border:1px solid #ccc;list-style-type:none;width:100%;overflow:auto}.llms-notice-box input[type=text]{height:auto}.llms-notice-box .col-1-1{width:100%}.llms-notice-box .col-1-1 input[type=text]{width:100%}.llms-notice-box .col-1-2{width:50%;float:right}@media screen and (max-width: 768px){.llms-notice-box .col-1-2{width:100%}}.llms-notice-box .col-1-3{width:33%;float:right;margin-left:10px}.llms-notice-box .col-1-4{width:25%;float:right;margin-left:10px}@media screen and (max-width: 768px){.llms-notice-box .col-1-4{width:100%}}.llms-notice-box .col-1-6{width:16.6%;float:right;margin-left:10px}.llms-notice-box .col-1-8{width:11%;float:left}.llms-notice-box .llms-pad-right{padding-left:10px}@media screen and (max-width: 768px){.llms-notice-box .llms-pad-right{padding-left:0}}input[type=text].cc_cvv,#cc_cvv{margin-left:0;width:23%;float:left}.llms-clear-box{border-radius:3px;z-index:10;margin:10px 0;padding:15px 20px;list-style-type:none;width:100%;overflow:auto}.llms-price-label{font-weight:normal}.llms-final-price{font-weight:bold;float:left}.llms-center-content{text-align:center}.llms-input-text{background-color:#fff;border:1px solid #ddd;color:#333;font-size:18px;font-weight:300;padding:16px;width:100%}.llms-price{margin-bottom:0;font-weight:bold}.llms-price-loop{margin-bottom:0;font-weight:bold}.courses .entry{padding:0}.list-view .site-content .llms-course-list .hentry,.list-view .site-content .llms-membership-list .hentry{border-top:0;padding-top:0}.llms-content{width:100%}.llms-lesson-button-wrapper{width:100%;display:block;clear:both;text-align:center}.llms-template-wrapper{width:100%;display:block;clear:both}.llms-button-wrapper{width:100%;display:block;clear:both;text-align:center}.llms-styled-select{border:1px solid #ccc;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:3px;overflow:hidden;position:relative}.llms-styled-select,.llms-styled-select select{width:100%}select:focus{outline:none}.llms-styled-select select{height:34px;padding:5px 5px 5px 0;background:rgba(0,0,0,0);border:none;-webkit-appearance:none;font-size:16px;color:#444}@-moz-document url-prefix(){.--ms-styled-select select{width:110%}}.llms-styled-select .fa-sort-desc{position:absolute;top:0;left:12px;font-size:24px;color:#ccc}select::-ms-expand{display:none}_:-o-prefocus .llms-styled-select,.selector .llms-styled-select{background:none}.llms-form-item-wrapper{margin-bottom:1em}.llms-progress-circle{position:relative;width:200px;height:200px;float:right}.llms-progress-circle-count{top:27%;position:absolute;width:94%;text-align:center;color:#666;font-size:44px}.llms-progress-circle svg{position:absolute;width:200px;height:200px}.llms-progress-circle circle{fill:rgba(0,0,0,0)}svg .llms-background-circle{fill:rgba(0,0,0,0);stroke-width:10px;stroke:#f1f2f1;stroke-dasharray:430}svg .llms-animated-circle{fill:rgba(0,0,0,0);stroke-width:10px;stroke:#e5554e;stroke-dasharray:430;stroke-dashoffset:410}.llms-widget-syllabus .llms-lesson.current-lesson .lesson-title{font-weight:700}.llms-widget-syllabus .llms-lesson-complete,.llms-widget-syllabus .lesson-complete-placeholder{font-size:1.2em;margin-left:6px;color:#ccc}.llms-widget-syllabus .llms-lesson-complete.done,.llms-widget-syllabus .lesson-complete-placeholder.done{color:#e5554e}.llms-widget-syllabus .section-title{font-weight:bold}.llms-widget-syllabus .lesson-title a{text-decoration:none}.llms-widget-syllabus .lesson-title a:hover{text-decoration:none !important}.llms-widget-syllabus .lesson-title.done a{color:#999;text-decoration:line-through}.llms-widget-syllabus ul{list-style-type:none}.llms-widget-syllabus ul li{list-style-type:none}.llms-widget-syllabus ul li ul li{margin:0 0 2px 0;padding:0}.llms-remove-coupon{float:left}.llms-lesson-link-locked,.llms-lesson-link-locked:hover{background:#f1f1f1;-webkit-box-shadow:0 1px 2px 0 rgba(1,1,1,.4);box-shadow:0 1px 2px 0 rgba(1,1,1,.4);display:block;color:#a6a6a6;min-height:85px;padding:15px;text-decoration:none;position:relative}.llms-lesson-preview.is-complete .llms-lesson-link-locked{padding-right:75px}.llms-lesson-tooltip{display:none;position:absolute;color:#000;background-color:silver;padding:.25em;border-radius:2px;z-index:100;top:0;right:50%;text-align:center;-webkit-transform:translateX(50%) translateY(-100%);transform:translateX(50%) translateY(-100%)}.llms-lesson-tooltip:after{content:"";width:0;height:0;border-top:8px solid silver;border-right:8px solid rgba(0,0,0,0);border-left:8px solid rgba(0,0,0,0);position:absolute;bottom:-8px;right:50%;-webkit-transform:translateX(50%);transform:translateX(50%)}.llms-lesson-tooltip.active{display:inline-block}.llms-loop-list{list-style:none;margin:0 -10px;padding:0}@media all and (min-width: 600px){.llms-loop-list.cols-1 .llms-loop-item{width:100%}.llms-loop-list.cols-2 .llms-loop-item{width:50%}.llms-loop-list.cols-3 .llms-loop-item{width:33.3333333333%}.llms-loop-list.cols-4 .llms-loop-item{width:25%}.llms-loop-list.cols-5 .llms-loop-item{width:20%}.llms-loop-list.cols-6 .llms-loop-item{width:16.6666666667%}}.llms-loop-item{float:right;list-style:none;margin:0;padding:0;width:100%}.llms-loop-item-content{background:#f1f1f1;padding-bottom:10px;margin:10px}.llms-loop-item-content:hover{background:#eaeaea}.llms-loop-item-content .llms-loop-link{color:#212121;display:block}.llms-loop-item-content .llms-loop-link:visited{color:#212121}.llms-loop-item-content .llms-featured-image{display:block;max-width:100%}.llms-loop-item-content .llms-loop-title{margin-top:5px}.llms-loop-item-content .llms-loop-title:hover{color:#2295ff}.llms-loop-item-content .llms-meta,.llms-loop-item-content .llms-author,.llms-loop-item-content .llms-loop-title{padding:0 10px}.llms-loop-item-content .llms-meta,.llms-loop-item-content .llms-author{color:#444;display:block;font-size:13px;margin-bottom:3px}.llms-loop-item-content .llms-meta:last-child,.llms-loop-item-content .llms-author:last-child{margin-bottom:0}.llms-loop-item-content .llms-featured-img-wrap{overflow:hidden}.llms-loop-item-content p{margin-bottom:0}.llms-loop-item-content .llms-progress{margin:0;height:.4em}.llms-loop-item-content .llms-progress .progress__indicator{display:none}.llms-loop-item-content .llms-progress .llms-progress-bar{background-color:#f6f6f6;left:0;top:0}.course .llms-meta-info{margin:20px 0}.course .llms-meta-info .llms-meta-title{margin-bottom:5px}.course .llms-meta-info .llms-meta p{margin-bottom:0}.course .llms-meta-info .llms-meta span{font-weight:700}.course .llms-course-progress{margin:40px auto;max-width:480px;text-align:center}.llms-syllabus-wrapper{margin:15px;text-align:center}.llms-syllabus-wrapper .llms-section-title{margin:25px 0 0}.llms-course-navigation .llms-prev-lesson,.llms-course-navigation .llms-next-lesson,.llms-course-navigation .llms-back-to-course{width:49%}.llms-course-navigation .llms-prev-lesson,.llms-course-navigation .llms-back-to-course{float:right;margin-left:.5%}.llms-course-navigation .llms-next-lesson,.llms-course-navigation .llms-prev-lesson+.llms-back-to-course{float:left;margin-right:.5%}.llms-lesson-preview{display:inline-block;margin-top:15px;max-width:100%;position:relative;width:480px}.llms-lesson-preview .llms-lesson-link{background:#f1f1f1;color:#212121;display:block;padding:15px;text-decoration:none}.llms-lesson-preview .llms-lesson-link:before,.llms-lesson-preview .llms-lesson-link:after{content:" ";display:table}.llms-lesson-preview .llms-lesson-link:after{clear:both}.llms-lesson-preview .llms-lesson-link:hover{background:#eaeaea}.llms-lesson-preview .llms-lesson-link:visited{color:#212121}.llms-lesson-preview .llms-lesson-thumbnail{margin-bottom:10px}.llms-lesson-preview .llms-lesson-thumbnail img{display:block;width:100%}.llms-lesson-preview .llms-pre-text{text-align:right}.llms-lesson-preview .llms-lesson-title{font-weight:700;margin:0 auto 10px;text-align:right}.llms-lesson-preview .llms-lesson-title:last-child{margin-bottom:0}.llms-lesson-preview .llms-lesson-excerpt{text-align:right}.llms-lesson-preview .llms-main{float:right;width:100%}.llms-lesson-preview .llms-extra{float:left;width:15%}.llms-lesson-preview .llms-extra+.llms-main{width:85%}.llms-lesson-preview .llms-lesson-counter,.llms-lesson-preview .llms-free-lesson-svg,.llms-lesson-preview .llms-lesson-complete,.llms-lesson-preview .llms-lesson-complete-placeholder{display:block;font-size:32px;margin-bottom:15px}.llms-lesson-preview.is-free .llms-lesson-complete,.llms-lesson-preview.is-complete .llms-lesson-complete{color:#2295ff}.llms-lesson-preview .llms-icon-free{background:#2295ff;border-radius:4px;color:#f1f1f1;display:inline-block;padding:5px 6px 4px;line-height:1;font-size:14px}.llms-lesson-preview.is-incomplete .llms-lesson-complete{color:#cacaca}.llms-lesson-preview .llms-lesson-counter{font-size:16px;line-height:1}.llms-lesson-preview .llms-free-lesson-svg{fill:currentColor;height:23px;width:50px}.llms-lesson-preview p{margin-bottom:0}.llms-progress{clear:both;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:reverse;-ms-flex-direction:row-reverse;flex-direction:row-reverse;position:relative;height:1em;width:100%;margin:15px 0}.llms-progress .llms-progress-bar{background-color:#f1f2f1;position:relative;height:.4em;top:.3em;width:100%}.llms-progress .progress-bar-complete{background-color:#ef476f;height:100%}.progress__indicator{float:left;text-align:left;height:1em;line-height:1em;margin-right:5px;white-space:nowrap}.llms-author .name{margin-right:5px}.llms-author .label{margin-right:5px}.llms-author .avatar{border-radius:50%}.llms-author .bio{margin-top:5px}.llms-instructor-info .llms-instructors .llms-col:first-child .llms-author{margin-right:0}.llms-instructor-info .llms-instructors .llms-col:last-child .llms-author{margin-left:0}.llms-instructor-info .llms-instructors .llms-author{background:#f5f5f5;border-top:4px solid #2295ff;text-align:center;margin:45px 5px 5px;padding:0 10px 10px}.llms-instructor-info .llms-instructors .llms-author .avatar{background:#2295ff;border:4px solid #2295ff;display:block;margin:-35px auto 10px}.llms-instructor-info .llms-instructors .llms-author .llms-author-info{display:block}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.name{font-weight:700}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.label{font-size:85%}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.bio{font-size:90%;margin-bottom:0}.llms_review{margin:20px 0px;padding:10px}.llms_review h5{font-size:17px;margin:3px 0px}.llms_review h6{font-size:13px}.llms_review p{font-size:15px}.review_box [type=text]{margin:10px 0px}.review_box h5{color:red;display:none}.review_box+.thank_you_box{display:none}.llms-notice{background:rgba(34,149,255,.3);border-color:#2295ff;border-style:solid;border-width:3px;padding:10px;margin-bottom:10px}.llms-notice p:last-child,.llms-notice ul:last-child{margin-bottom:0}.llms-notice li{list-style-type:none}.llms-notice.llms-debug{background:rgba(202,202,202,.3);border-color:#cacaca}.llms-notice.llms-error{background:rgba(229,85,78,.3);border-color:#e5554e}.llms-notice.llms-success{background:rgba(131,195,115,.3);border-color:#83c373}.entry-content .llms-notice{margin:0 0 10px}.entry-content .llms-notice li{list-style-type:none}ul.llms-achievements-loop,.lifterlms ul.llms-achievements-loop,ul.llms-certificates-loop,.lifterlms ul.llms-certificates-loop{list-style-type:none;margin:0 -10px;padding:0}ul.llms-achievements-loop:before,ul.llms-achievements-loop:after,.lifterlms ul.llms-achievements-loop:before,.lifterlms ul.llms-achievements-loop:after,ul.llms-certificates-loop:before,ul.llms-certificates-loop:after,.lifterlms ul.llms-certificates-loop:before,.lifterlms ul.llms-certificates-loop:after{content:" ";display:table}ul.llms-achievements-loop:after,.lifterlms ul.llms-achievements-loop:after,ul.llms-certificates-loop:after,.lifterlms ul.llms-certificates-loop:after{clear:both}ul.llms-achievements-loop li.llms-achievement-loop-item,ul.llms-achievements-loop li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop li.llms-certificate-loop-item,ul.llms-certificates-loop li.llms-achievement-loop-item,ul.llms-certificates-loop li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop li.llms-certificate-loop-item{-webkit-box-sizing:border-box;box-sizing:border-box;display:block;float:right;list-style-type:none;margin:0;padding:10px;width:100%}@media all and (min-width: 600px){ul.llms-achievements-loop.loop-cols-1 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-1 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-1 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-1 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-1 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-1 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-1 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-1 li.llms-certificate-loop-item{width:100%}ul.llms-achievements-loop.loop-cols-2 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-2 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-2 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-2 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-2 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-2 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-2 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-2 li.llms-certificate-loop-item{width:50%}ul.llms-achievements-loop.loop-cols-3 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-3 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-3 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-3 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-3 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-3 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-3 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-3 li.llms-certificate-loop-item{width:33.3333333333%}ul.llms-achievements-loop.loop-cols-4 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-4 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-4 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-4 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-4 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-4 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-4 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-4 li.llms-certificate-loop-item{width:25%}ul.llms-achievements-loop.loop-cols-5 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-5 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-5 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-5 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-5 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-5 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-5 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-5 li.llms-certificate-loop-item{width:20%}}.llms-achievement,.llms-certificate{background:#f1f1f1;border:none;color:inherit;display:block;text-decoration:none;width:100%}.llms-achievement:hover,.llms-certificate:hover{background:#eaeaea}.llms-achievement .llms-achievement-img,.llms-certificate .llms-achievement-img{display:block;margin:0;width:100%}.llms-achievement .llms-achievement-title,.llms-certificate .llms-achievement-title{font-size:16px;margin:0;padding:10px;text-align:center}.llms-achievement .llms-certificate-title,.llms-certificate .llms-certificate-title{font-size:16px;margin:0;padding:0 0 10px}.llms-achievement .llms-achievement-info,.llms-achievement .llms-achievement-date,.llms-certificate .llms-achievement-info,.llms-certificate .llms-achievement-date{display:none}.llms-achievement .llms-achievement-content,.llms-certificate .llms-achievement-content{padding:20px}.llms-achievement .llms-achievement-content:empty,.llms-certificate .llms-achievement-content:empty{padding:0}.llms-achievement .llms-achievement-content *:last-child,.llms-certificate .llms-achievement-content *:last-child{margin-bottom:0}.llms-certificate{border:4px double #f1f1f1;padding:20px 10px;background:#fff;text-align:center}.llms-certificate:hover{background:#fff;border-color:#eaeaea}.llms-achievement-modal .llms-achievement{background:#fff}.llms-achievement-modal .llms-achievement-info{display:block}.llms-achievement-modal .llms-achievement-title{display:none}.llms-notification{background:#fff;-webkit-box-shadow:0 1px 2px -2px #333,0 1px 1px -1px #333;box-shadow:0 1px 2px -2px #333,0 1px 1px -1px #333;border-top:4px solid #2295ff;opacity:0;padding:12px;position:fixed;left:-800px;top:24px;-webkit-transition:opacity .4s ease-in-out,left .4s ease-in-out;transition:opacity .4s ease-in-out,left .4s ease-in-out;visibility:hidden;width:auto;z-index:9999999}.llms-notification:before,.llms-notification:after{content:" ";display:table}.llms-notification:after{clear:both}.llms-notification.visible{right:12px;opacity:1;left:12px;-webkit-transition:opacity .4s ease-in-out,left .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,-webkit-transform .2s ease-in-out;transition:opacity .4s ease-in-out,left .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,-webkit-transform .2s ease-in-out;transition:opacity .4s ease-in-out,left .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,transform .2s ease-in-out;transition:opacity .4s ease-in-out,left .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,transform .2s ease-in-out,-webkit-transform .2s ease-in-out;visibility:visible}.llms-notification.visible:hover .llms-notification-dismiss{opacity:1}.llms-notification .llms-notification-content{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex}.llms-notification .llms-notification-main{-ms-flex-item-align:start;align-self:flex-start;-webkit-box-flex:4;-ms-flex:4;flex:4;-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2}.llms-notification .llms-notification-title{font-size:18px;margin:0}.llms-notification .llms-notification-body{font-size:14px;line-height:1.4}.llms-notification .llms-notification-body p,.llms-notification .llms-notification-body li{font-size:inherit}.llms-notification .llms-notification-body p{margin-bottom:8px}.llms-notification .llms-notification-body .llms-mini-cert{background:#f6f6f6;border:1px solid #d0d0d0;-webkit-box-shadow:inset 0 0 0 3px #fefefe,inset 0 0 0 4px #dedede;box-shadow:inset 0 0 0 3px #fefefe,inset 0 0 0 4px #dedede;padding:16px 16px 24px;margin-top:12px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert-title{font-size:16px;font-weight:700;margin:12px auto;text-align:center}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body{width:100%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(1){width:65%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(2){width:35%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(3){width:85%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(4){width:75%;margin-top:18px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(5){width:70%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(6){margin-right:12px;margin-bottom:-24px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(7){width:65%;margin-left:12px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--mock-line{border-radius:2px;height:8px;background:#b0b0b0;background-image:-webkit-gradient(linear, right top, left top, from(#b0b0b0), color-stop(20%, #a0a0a0), color-stop(40%, #b0b0b0), to(#b0b0b0));background-image:linear-gradient(to left, #b0b0b0 0%, #a0a0a0 20%, #b0b0b0 40%, #b0b0b0 100%);background-repeat:no-repeat;margin:4px auto}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--mock-dot{background:#b0b0b0;border-radius:50%;display:inline-block;content:"";height:24px;width:24px}.llms-notification .llms-notification-body .llms-mini-cert p{margin-bottom:0}.llms-notification .llms-notification-aside{-ms-flex-item-align:start;align-self:flex-start;-webkit-box-flex:1;-ms-flex:1;flex:1;margin-left:12px;-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1}.llms-notification .llms-notification-icon{display:block;max-width:64px}.llms-notification .llms-notification-footer{border-top:1px solid #e5e5e5;font-size:12px;margin-top:12px;padding:6px 6px 0;text-align:left}.llms-notification .llms-notification-dismiss{color:#e5554e;cursor:pointer;font-size:22px;position:absolute;left:10px;top:8px;-webkit-transition:opacity .4s ease-in-out;transition:opacity .4s ease-in-out}.llms-sd-notification-center .llms-notification-list,.llms-sd-notification-center .llms-notification-list-item{list-style-type:none;margin:0;padding:0}.llms-sd-notification-center .llms-notification-list-item:hover .llms-notification{background:#fcfcfc}.llms-sd-notification-center .llms-notification{opacity:1;border-top:1px solid #e5e5e5;right:auto;padding:24px;position:relative;left:auto;top:auto;visibility:visible;width:auto}.llms-sd-notification-center .llms-notification .llms-notification-aside{max-width:64px}.llms-sd-notification-center .llms-notification .llms-notification-footer{border:none;padding:0;text-align:right}.llms-sd-notification-center .llms-notification .llms-progress{display:none !important}.llms-sd-notification-center .llms-notification .llms-notification-date{color:#515151;float:right;margin-left:6px}.llms-sd-notification-center .llms-notification .llms-mini-cert{margin:0 auto;max-width:380px}@media all and (min-width: 480px){.llms-notification{left:-800px;width:360px}.llms-notification.visible{right:auto;left:24px}.llms-notification .llms-notification-dismiss{opacity:0}}.llms-pagination ul{list-style-type:none}.llms-pagination ul li{float:right}.llms-pagination ul li a{border-bottom:0;text-decoration:none}.llms-pagination ul li .page-numbers{padding:.5em;text-decoration:underline}.llms-pagination ul li .page-numbers.current{text-decoration:none}.llms-tooltip{background:#2a2a2a;border-radius:4px;color:#fff;font-size:14px;line-height:1.2;opacity:0;top:-20px;padding:8px 12px;right:50%;position:absolute;pointer-events:none;-webkit-transform:translateX(50%);transform:translateX(50%);-webkit-transition:opacity .2s ease,top .2s ease;transition:opacity .2s ease,top .2s ease;max-width:320px}.llms-tooltip.show{top:-28px;opacity:1}.llms-tooltip:after{bottom:-8px;border-top:8px solid #2a2a2a;border-right:8px solid rgba(0,0,0,0);border-left:8px solid rgba(0,0,0,0);content:"";height:0;right:50%;position:absolute;-webkit-transform:translateX(50%);transform:translateX(50%);width:0}.webui-popover-title{font-size:initial;font-weight:initial;line-height:initial}.webui-popover-inverse .webui-popover-inner .close{color:#fff;opacity:.6;text-shadow:none}.webui-popover-inverse .webui-popover-inner .close:hover{opacity:.8}.webui-popover-inverse .webui-popover-content a{color:#fff;text-decoration:underline}.webui-popover-inverse .webui-popover-content a:hover{text-decoration:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results{margin:0;padding:0;list-style-type:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question{background:#efefef;margin:0 0 10px;position:relative;list-style-type:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer{color:inherit;display:block;padding:10px 10px 10px 35px;text-decoration:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:before,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:after{content:" ";display:table}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:after{clear:both}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.correct,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.incorrect{background:rgba(255,146,43,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.correct .llms-status-icon,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.incorrect .llms-status-icon{background-color:#ff922b}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.correct{background:rgba(131,195,115,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.correct .llms-status-icon{background-color:#83c373}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.incorrect{background:rgba(229,85,78,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.incorrect .llms-status-icon{background-color:#e5554e}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question pre{overflow:auto}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-question-title{float:right;margin:0;line-height:1}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-points{float:left;line-height:1}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-status-icon-tip{position:absolute;left:-12px;top:-2px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-status-icon{color:rgba(255,255,255,.65);border-radius:50%;font-size:30px;height:40px;line-height:40px;text-align:center;width:40px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main{display:none;padding:0 10px 10px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-results-label{font-weight:700;margin-bottom:10px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers{margin:0;padding:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer{padding:0;margin:0 30px 0 0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer:only-child{list-style-type:none;margin-right:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main img{height:auto;max-width:200px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-attempt-answer-section{border-top:2px solid rgba(255,255,255,.5);margin-top:20px;padding-top:20px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-attempt-answer-section:first-child{border-top:none;margin-top:0;padding-top:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_choice ul.llms-quiz-attempt-answers,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_reorder ul.llms-quiz-attempt-answers{list-style-type:none;margin:0;padding:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_choice ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_reorder ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer{display:inline-block;list-style-type:none;margin:0;padding:5px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--removed{opacity:.5}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--removed .llms-question-title{font-style:italic;font-weight:normal}.single-llms_quiz .llms-return{margin-bottom:10px}.single-llms_quiz .llms-quiz-results:before,.single-llms_quiz .llms-quiz-results:after{content:" ";display:table}.single-llms_quiz .llms-quiz-results:after{clear:both}.single-llms_quiz .llms-quiz-results .llms-donut.passing{color:#83c373}.single-llms_quiz .llms-quiz-results .llms-donut.passing svg path{stroke:#83c373}.single-llms_quiz .llms-quiz-results .llms-donut.pending{color:#555}.single-llms_quiz .llms-quiz-results .llms-donut.pending svg path{stroke:#555}.single-llms_quiz .llms-quiz-results .llms-donut.failing{color:#e5554e}.single-llms_quiz .llms-quiz-results .llms-donut.failing svg path{stroke:#e5554e}.single-llms_quiz .llms-quiz-results .llms-quiz-results-aside,.single-llms_quiz .llms-quiz-results .llms-quiz-results-main,.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{margin-bottom:20px}@media all and (min-width: 600px){.single-llms_quiz .llms-quiz-results .llms-quiz-results-aside{float:right;width:220px}.single-llms_quiz .llms-quiz-results .llms-quiz-results-main,.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{float:left;width:calc(100% - 300px)}.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{clear:left}}.single-llms_quiz ul.llms-quiz-meta-info,.single-llms_quiz ul.llms-quiz-meta-info li{list-style-type:none;margin:0;padding:0}.single-llms_quiz ul.llms-quiz-meta-info{margin-bottom:10px}.single-llms_quiz .llms-quiz-buttons{margin-top:10px;text-align:right}.single-llms_quiz .llms-quiz-buttons form{display:inline-block}.llms-quiz-question-wrapper{min-height:140px;position:relative}.llms-quiz-question-wrapper .llms-quiz-loading{bottom:20px;right:0;position:absolute;left:0;text-align:center;z-index:1}.llms-quiz-ui{background:#fcfcfc;padding:20px;position:relative}.llms-quiz-ui .llms-quiz-header{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex;margin:0 0 30px}.llms-quiz-ui .llms-progress{background-color:#f1f2f1;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;height:8px;margin:0;overflow:hidden}.llms-quiz-ui .llms-progress .progress-bar-complete{-webkit-transition:width .3s ease-in;transition:width .3s ease-in;width:0}.llms-quiz-ui .llms-error{background:#e5554e;border-radius:4px;color:#fff;margin:10px 0;padding:10px}.llms-quiz-ui .llms-error:before,.llms-quiz-ui .llms-error:after{content:" ";display:table}.llms-quiz-ui .llms-error:after{clear:both}.llms-quiz-ui .llms-error a{color:rgba(255,255,255,.6);float:left;font-size:22px;line-height:1;text-decoration:none}.llms-quiz-ui .llms-quiz-counter{display:none;color:#6a6a6a;float:left;font-size:18px}.llms-quiz-ui .llms-quiz-counter .llms-sep{margin:0 5px}.llms-quiz-ui .llms-quiz-nav{margin-top:20px}.llms-quiz-ui .llms-quiz-nav button{margin:0 0 0 10px}.llms-question-wrapper .llms-question-text{font-size:30px;font-weight:400;margin-bottom:15px}.llms-question-wrapper ol.llms-question-choices{list-style-type:none;margin:0;padding:0}.llms-question-wrapper ol.llms-question-choices li.llms-choice{border-bottom:1px solid #e8e8e8;margin:0;padding:0;position:relative}.llms-question-wrapper ol.llms-question-choices li.llms-choice:last-child{border-bottom:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture{border-bottom:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture label{display:inline-block;padding:0}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-marker{bottom:10px;margin:0;position:absolute;left:10px}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-choice-image{margin:2px;padding:20px;-webkit-transition:background .4s ease;transition:background .4s ease}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-choice-image img{display:block;width:100%}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture input:checked~.llms-choice-image{background:#efefef}.llms-question-wrapper ol.llms-question-choices li.llms-choice input{display:none;right:0;pointer-events:none;position:absolute;top:0;visibility:hidden}.llms-question-wrapper ol.llms-question-choices li.llms-choice label{display:block;margin:0;padding:10px 20px;position:relative}.llms-question-wrapper ol.llms-question-choices li.llms-choice label.hovered .llms-marker:not(.type--lister) .iterator{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice label.hovered .llms-marker:not(.type--lister) .fa{display:inline}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker{background:#f0f0f0;display:inline-block;font-size:20px;height:40px;line-height:40px;margin-left:10px;text-align:center;-webkit-transition:all .2s ease;transition:all .2s ease;vertical-align:middle;width:40px}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker .fa{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--lister,.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--checkbox{border-radius:4px}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--radio{border-radius:50%}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker{background:#ef476f;color:#fff}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker .iterator{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker .fa{display:inline}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-choice-text{display:inline-block;font-size:18px;font-weight:400;line-height:1.6;margin-bottom:0;vertical-align:middle;width:calc(100% - 60px)}.llms-quiz-timer{background:#fff;border:1px solid #83c373;border-radius:4px;color:#83c373;float:left;font-size:18px;line-height:1;margin-right:20px;padding:8px 12px;position:relative;white-space:nowrap;z-index:1}.llms-quiz-timer.color-half{border-color:#ff922b;color:#ff922b}.llms-quiz-timer.color-empty{border-color:#e5554e;color:#e5554e}.llms-quiz-timer .llms-tiles{display:inline-block;margin-right:5px}.voucher-expand{display:none}@media all and (min-width: 600px){.llms-access-plans.cols-1 .llms-access-plan{width:100%}.llms-access-plans.cols-2 .llms-access-plan{width:50%}.llms-access-plans.cols-3 .llms-access-plan{width:33.3333333333%}.llms-access-plans.cols-4 .llms-access-plan{width:25%}.llms-access-plans.cols-5 .llms-access-plan{width:20%}}.llms-free-enroll-form{margin-bottom:0}.llms-access-plan{-webkit-box-sizing:border-box;box-sizing:border-box;float:right;text-align:center;width:100%}.llms-access-plan .llms-access-plan-footer,.llms-access-plan .llms-access-plan-content{background:#f1f1f1}.llms-access-plan.featured .llms-access-plan-featured{background:#4ba9ff}.llms-access-plan.featured .llms-access-plan-footer,.llms-access-plan.featured .llms-access-plan-content{border-right:3px solid #2295ff;border-left:3px solid #2295ff}.llms-access-plan.featured .llms-access-plan-footer{border-bottom-color:#2295ff}.llms-access-plan.on-sale .price-regular{text-decoration:line-through}.llms-access-plan .stamp{background:#2295ff;color:#fff;font-size:11px;font-style:normal;font-weight:300;padding:2px 3px;vertical-align:top}.llms-access-plan .llms-access-plan-restrictions ul{margin:0}.llms-access-plan-featured{color:#fff;font-size:14px;font-weight:400;margin:0 2px 0 2px}.llms-access-plan-content{margin:0 2px 0}.llms-access-plan-content .llms-access-plan-pricing{padding:10px 0 0}.llms-access-plan-title{background:#2295ff;color:#fff;margin-bottom:0;padding:10px}.llms-access-plan-pricing .llms-price-currency-symbol{font-size:14px;vertical-align:top}.llms-access-plan-price{font-size:18px;font-variant:small-caps;line-height:20px}.llms-access-plan-price .lifterlms-price{font-weight:700}.llms-access-plan-price.sale{padding:5px 0;border-top:1px solid #d0d0d0;border-bottom:1px solid #d0d0d0}.llms-access-plan-trial,.llms-access-plan-schedule,.llms-access-plan-sale-end,.llms-access-plan-expiration{font-size:15px;font-variant:small-caps;line-height:1.2}.llms-access-plan-description{font-size:16px;padding:10px 10px 0}.llms-access-plan-description ul{margin:0}.llms-access-plan-description ul li{border-bottom:1px solid #d0d0d0;list-style-type:none}.llms-access-plan-description ul li:last-child{border-bottom:none}.llms-access-plan-description div:last-child,.llms-access-plan-description img:last-child,.llms-access-plan-description p:last-child,.llms-access-plan-description ul:last-child,.llms-access-plan-description li:last-child{margin-bottom:0}.llms-access-plan-restrictions .stamp{vertical-align:baseline}.llms-access-plan-restrictions ul{margin:0}.llms-access-plan-restrictions ul li{font-size:12px;line-height:14px;list-style-type:none}.llms-access-plan-restrictions a{color:#f8954f}.llms-access-plan-restrictions a:hover{color:#f67d28}.llms-access-plan-footer{border-bottom:3px solid #f1f1f1;padding:10px;margin:0 2px 2px 2px}.llms-access-plan-footer .llms-access-plan-pricing{padding:0 0 10px}.webui-popover-content .llms-members-only-restrictions{text-align:center}.webui-popover-content .llms-members-only-restrictions ul,.webui-popover-content .llms-members-only-restrictions ol,.webui-popover-content .llms-members-only-restrictions li,.webui-popover-content .llms-members-only-restrictions p{margin:0;padding:0}.webui-popover-content .llms-members-only-restrictions ul,.webui-popover-content .llms-members-only-restrictions ol,.webui-popover-content .llms-members-only-restrictions li{list-style-type:none}.webui-popover-content .llms-members-only-restrictions li{padding:8px 0;border-top:1px solid #3b3b3b}.webui-popover-content .llms-members-only-restrictions li:first-child{border-top:none}.webui-popover-content .llms-members-only-restrictions li a{display:block}.llms-checkout-wrapper form.llms-login{border:3px solid #2295ff;display:none;margin-bottom:10px}.llms-checkout-wrapper .llms-form-heading{background:#2295ff;color:#fff;margin:0 0 5px;padding:10px}.llms-checkout{background:#fff;position:relative}@media all and (min-width: 800px){.llms-checkout-cols-2 .llms-checkout-col{float:right}.llms-checkout-cols-2 .llms-checkout-col.llms-col-1{margin-left:5px;width:calc(58% - 5px)}.llms-checkout-cols-2 .llms-checkout-col.llms-col-2{margin-right:5px;width:calc(42% - 5px)}.llms-checkout-cols-2 .llms-checkout-col.llms-col-2 button{width:100%}}.llms-checkout-section{border:3px solid #2295ff;margin-bottom:10px;position:relative}.llms-checkout-section-content{margin:10px}.llms-checkout-section-content.llms-form-fields{margin:0px}.llms-checkout-section-content .llms-label{font-weight:400;font-variant:small-caps;text-transform:lowercase}.llms-checkout-section-content .llms-order-summary{list-style-type:none;margin:0;padding:0}.llms-checkout-section-content .llms-order-summary li{list-style-type:none}.llms-checkout-section-content .llms-order-summary li.llms-pricing.on-sale .price-regular,.llms-checkout-section-content .llms-order-summary li.llms-pricing.has-coupon .price-regular{text-decoration:line-through}.llms-checkout-section-content .llms-coupon-wrapper{border-top:1px solid #dadada;margin-top:10px;padding-top:10px}.llms-checkout-section-content .llms-coupon-wrapper .llms-coupon-entry{display:none;margin-top:10px}.llms-form-field.llms-payment-gateway-option label+span.llms-description{display:inline-block;margin-right:5px}.llms-form-field.llms-payment-gateway-option .llms-description a{border:none;-webkit-box-shadow:none;box-shadow:none;text-decoration:none}.llms-form-field.llms-payment-gateway-option .llms-description img{display:inline;max-height:22px;vertical-align:middle}.llms-checkout-wrapper ul.llms-payment-gateways{margin:5px 0 0;padding:0}ul.llms-payment-gateways{list-style-type:none}ul.llms-payment-gateways li:last-child:after{border-bottom:1px solid #dadada;content:"";display:block;margin:10px}ul.llms-payment-gateways .llms-payment-gateway{margin-bottom:5px;list-style-type:none}ul.llms-payment-gateways .llms-payment-gateway:last-child{margin-bottom:none}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-payment-gateway-option label{font-weight:700}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-gateway-fields{display:block}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-gateway-fields .llms-notice{margin-right:10px;margin-left:10px}ul.llms-payment-gateways .llms-payment-gateway .llms-form-field{padding-bottom:0}ul.llms-payment-gateways .llms-gateway-description{margin-right:40px}ul.llms-payment-gateways .llms-gateway-fields{display:none;margin:5px 0 20px}ul.llms-payment-gateways .llms-payment-gateway-error{padding:0 10px}.llms-checkout-confirm{margin:0 10px}.llms-payment-method{margin:10px 10px 0}.llms-gateway-description p{font-size:85%;font-style:italic;margin-bottom:0}.llms-form-fields{-webkit-box-sizing:border-box;box-sizing:border-box}.llms-form-fields *{-webkit-box-sizing:border-box;box-sizing:border-box}.llms-form-fields.flush .llms-form-field{padding:0 0 10px}.llms-form-fields .wp-block-columns,.llms-form-fields .wp-block-column{margin-bottom:0}.llms-form-heading{padding:0 10px 10px}.llms-form-field{float:right;padding:0 10px 10px;position:relative;width:100%}.llms-form-field label:empty:after{content:" "}.llms-form-field.valid input[type=date],.llms-form-field.valid input[type=time],.llms-form-field.valid input[type=datetime-local],.llms-form-field.valid input[type=week],.llms-form-field.valid input[type=month],.llms-form-field.valid input[type=text],.llms-form-field.valid input[type=email],.llms-form-field.valid input[type=url],.llms-form-field.valid input[type=password],.llms-form-field.valid input[type=search],.llms-form-field.valid input[type=tel],.llms-form-field.valid input[type=number],.llms-form-field.valid textarea,.llms-form-field.valid select{background:rgba(131,195,115,.3);border-color:#83c373}.llms-form-field.error input[type=date],.llms-form-field.error input[type=time],.llms-form-field.error input[type=datetime-local],.llms-form-field.error input[type=week],.llms-form-field.error input[type=month],.llms-form-field.error input[type=text],.llms-form-field.error input[type=email],.llms-form-field.error input[type=url],.llms-form-field.error input[type=password],.llms-form-field.error input[type=search],.llms-form-field.error input[type=tel],.llms-form-field.error input[type=number],.llms-form-field.error textarea,.llms-form-field.error select,.llms-form-field.invalid input[type=date],.llms-form-field.invalid input[type=time],.llms-form-field.invalid input[type=datetime-local],.llms-form-field.invalid input[type=week],.llms-form-field.invalid input[type=month],.llms-form-field.invalid input[type=text],.llms-form-field.invalid input[type=email],.llms-form-field.invalid input[type=url],.llms-form-field.invalid input[type=password],.llms-form-field.invalid input[type=search],.llms-form-field.invalid input[type=tel],.llms-form-field.invalid input[type=number],.llms-form-field.invalid textarea,.llms-form-field.invalid select{background:rgba(229,85,78,.3);border-color:#e5554e}.llms-form-field.llms-visually-hidden-field{display:none}.llms-form-field.align-right{text-align:left}@media screen and (min-width: 600px){.llms-form-field.llms-cols-1{width:8.3333333333%}.llms-form-field.llms-cols-2{width:16.6666666667%}.llms-form-field.llms-cols-3{width:25%}.llms-form-field.llms-cols-4{width:33.3333333333%}.llms-form-field.llms-cols-5{width:41.6666666667%}.llms-form-field.llms-cols-6{width:50%}.llms-form-field.llms-cols-7{width:58.3333333333%}.llms-form-field.llms-cols-8{width:66.6666666667%}.llms-form-field.llms-cols-9{width:75%}.llms-form-field.llms-cols-10{width:83.3333333333%}.llms-form-field.llms-cols-11{width:91.6666666667%}.llms-form-field.llms-cols-12{width:100%}}.llms-form-field.type-hidden{padding:0}.llms-form-field.type-radio input,.llms-form-field.type-radio label,.llms-form-field.type-checkbox input,.llms-form-field.type-checkbox label{display:inline-block;width:auto}.llms-form-field.type-radio input,.llms-form-field.type-checkbox input{margin-left:5px}.llms-form-field.type-radio label+.llms-description,.llms-form-field.type-checkbox label+.llms-description{display:block}.llms-form-field.type-radio:not(.is-group) input[type=radio]{position:absolute;opacity:0;visibility:none}.llms-form-field.type-radio:not(.is-group) label:before{background:#fafafa;background-position:-24px 0;background-repeat:no-repeat;border-radius:50%;-webkit-box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.35) 0 0 0 1px;box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.35) 0 0 0 1px;content:"";cursor:pointer;display:inline-block;height:22px;margin-left:5px;position:relative;-webkit-transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);top:-3px;vertical-align:middle;width:22px;z-index:2}.llms-form-field.type-radio:not(.is-group) input[type=radio]:checked+label:before{-webkit-transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);background-position:100% 0;background-image:radial-gradient(ellipse at center, #2295ff 0%, #2295ff 40%, #fafafa 45%)}.llms-form-field .llms-input-group{margin-top:5px}.llms-form-field .llms-input-group .llms-form-field{padding:0 5px 5px 0}.llms-form-field.type-reset button:not(.auto),.llms-form-field.type-button button:not(.auto),.llms-form-field.type-submit button:not(.auto){width:100%}.llms-form-field .llms-description{font-size:14px;font-style:italic}.llms-form-field .llms-required{color:#e5554e;margin-right:4px}.llms-form-field input,.llms-form-field textarea,.llms-form-field select{width:100%;margin-bottom:5px}.llms-form-field .select2-container .select2-selection--single{height:auto;padding:4px 6px}.llms-form-field .select2-container--default .select2-selection--single .select2-selection__arrow{height:100%}.llms-password-strength-meter{border:1px solid #dadada;display:none;font-size:10px;margin-top:-10px;padding:1px;position:relative;text-align:center}.llms-password-strength-meter:before{bottom:0;content:"";right:0;position:absolute;top:0;-webkit-transition:width .4s ease;transition:width .4s ease}.llms-password-strength-meter.mismatch,.llms-password-strength-meter.too-short,.llms-password-strength-meter.very-weak{border-color:#e35b5b}.llms-password-strength-meter.mismatch:before,.llms-password-strength-meter.too-short:before,.llms-password-strength-meter.very-weak:before{background:rgba(227,91,91,.25);width:25%}.llms-password-strength-meter.too-short:before{width:0}.llms-password-strength-meter.weak{border-color:#f78b53}.llms-password-strength-meter.weak:before{background:rgba(247,139,83,.25);width:50%}.llms-password-strength-meter.medium{border-color:#ffc733}.llms-password-strength-meter.medium:before{background:rgba(255,199,51,.25);width:75%}.llms-password-strength-meter.strong{border-color:#83c373}.llms-password-strength-meter.strong:before{background:rgba(131,195,115,.25);width:100%}.llms-widget-syllabus--collapsible .llms-section .section-header{cursor:pointer}.llms-widget-syllabus--collapsible .llms-section.llms-section--opened .llms-collapse-caret .fa-caret-right{display:none}.llms-widget-syllabus--collapsible .llms-section.llms-section--closed .llms-collapse-caret .fa-caret-down{display:none}.llms-widget-syllabus--collapsible .llms-section.llms-section--closed .llms-lesson{display:none}.llms-widget-syllabus--collapsible .llms-syllabus-footer{text-align:right}.llms-student-dashboard .llms-sd-title{margin:25px 0}.llms-student-dashboard .llms-sd-items{list-style-type:none;margin:0;padding:0}.llms-student-dashboard .llms-sd-item{float:right;list-style-type:none;margin:0;padding:0}.llms-student-dashboard .llms-sd-item:last-child .llms-sep{display:none}.llms-student-dashboard .llms-sd-item .llms-sep{color:#333;margin:0 5px}.llms-student-dashboard .llms-sd-section{margin-bottom:25px}.llms-student-dashboard .llms-sd-section .llms-sd-section-footer{margin-top:10px}.llms-student-dashboard .orders-table{border:1px solid #f5f5f5;width:100%}.llms-student-dashboard .orders-table thead{display:none}.llms-student-dashboard .orders-table thead th,.llms-student-dashboard .orders-table thead td{font-weight:700}@media all and (min-width: 600px){.llms-student-dashboard .orders-table thead{display:table-header-group}}.llms-student-dashboard .orders-table tbody tr:nth-child(even) td,.llms-student-dashboard .orders-table tbody tr:nth-child(even) th{background:#f9f9f9}.llms-student-dashboard .orders-table tfoot th,.llms-student-dashboard .orders-table tfoot td{padding:10px;text-align:left}.llms-student-dashboard .orders-table tfoot th:last-child,.llms-student-dashboard .orders-table tfoot td:last-child{border-bottom-width:0}.llms-student-dashboard .orders-table th{font-weight:700}.llms-student-dashboard .orders-table th,.llms-student-dashboard .orders-table td{border-color:#efefef;border-style:solid;border-width:0;display:block;padding:8px 12px;text-align:center}.llms-student-dashboard .orders-table th .llms-button-primary,.llms-student-dashboard .orders-table td .llms-button-primary{display:inline-block}.llms-student-dashboard .orders-table th:last-child,.llms-student-dashboard .orders-table td:last-child{border-bottom-width:1px}.llms-student-dashboard .orders-table th:before,.llms-student-dashboard .orders-table td:before{content:attr(data-label)}@media all and (min-width: 600px){.llms-student-dashboard .orders-table th,.llms-student-dashboard .orders-table td{border-bottom-width:1px;display:table-cell;text-align:right}.llms-student-dashboard .orders-table th:first-child,.llms-student-dashboard .orders-table td:first-child{width:220px}.llms-student-dashboard .orders-table th:before,.llms-student-dashboard .orders-table td:before{display:none}}@media all and (min-width: 600px){.llms-student-dashboard .orders-table.transactions th:first-child{width:auto}}.llms-student-dashboard .llms-status{border-radius:3px;border-bottom:1px solid #fff;display:inline-block;font-size:80%;padding:3px 6px;vertical-align:middle}.llms-student-dashboard .llms-status.llms-size--large{font-size:105%;padding:6px 12px}.llms-student-dashboard .llms-status.llms-active,.llms-student-dashboard .llms-status.llms-completed,.llms-student-dashboard .llms-status.llms-pass,.llms-student-dashboard .llms-status.llms-txn-succeeded{color:#1f3818;background-color:#83c373}.llms-student-dashboard .llms-status.llms-fail,.llms-student-dashboard .llms-status.llms-failed,.llms-student-dashboard .llms-status.llms-expired,.llms-student-dashboard .llms-status.llms-cancelled,.llms-student-dashboard .llms-status.llms-txn-failed{color:#5a110d;background-color:#e5554e}.llms-student-dashboard .llms-status.llms-incomplete,.llms-student-dashboard .llms-status.llms-on-hold,.llms-student-dashboard .llms-status.llms-pending,.llms-student-dashboard .llms-status.llms-pending-cancel,.llms-student-dashboard .llms-status.llms-refunded,.llms-student-dashboard .llms-status.llms-txn-pending,.llms-student-dashboard .llms-status.llms-txn-refunded{color:#664200;background-color:orange}.llms-student-dashboard .llms-person-form-wrapper .llms-change-password{display:none}@media all and (min-width: 600px){.llms-student-dashboard .order-primary{float:right;width:68%}}@media all and (min-width: 600px){.llms-student-dashboard .order-secondary{float:right;width:32%}}.llms-student-dashboard .order-secondary form{margin-bottom:0}@media all and (min-width: 600px){.llms-student-dashboard .llms-view-order.llms-stack-cols .order-primary,.llms-student-dashboard .llms-view-order.llms-stack-cols .order-secondary{float:none;width:100%}}.llms-student-dashboard .llms-switch-payment-source .llms-notice,.llms-student-dashboard .llms-switch-payment-source .entry-content .llms-notice{margin-right:10px;margin-left:10px}.llms-student-dashboard .llms-switch-payment-source-main{border:none;display:none;margin:0}.llms-student-dashboard .llms-switch-payment-source-main ul.llms-payment-gateways{padding:10px 15px 0;margin:0}.llms-student-dashboard .llms-switch-payment-source-main .llms-payment-method,.llms-student-dashboard .llms-switch-payment-source-main ul.llms-order-summary{padding:0 25px 10px;margin:0;list-style-type:none}.llms-student-dashboard .llms-switch-payment-source-main .llms-payment-method li,.llms-student-dashboard .llms-switch-payment-source-main ul.llms-order-summary li{list-style-type:none}.llms-student-dashboard .llms-loop-list{margin:0 -10px}.llms-sd-grades .llms-table .llms-progress{display:block;margin:0}.llms-sd-grades .llms-table .llms-progress .llms-progress-bar{top:0;height:1.4em}.llms-sd-grades .llms-table .llms-progress .progress__indicator{font-size:1em;position:relative;left:.4em;top:.2em;z-index:1}.llms-table.llms-single-course-grades tbody tr:first-child td,.llms-table.llms-single-course-grades tbody tr:first-child th{background-color:#eaeaea}.llms-table.llms-single-course-grades th{font-weight:400}.llms-table.llms-single-course-grades td .llms-donut{display:inline-block;vertical-align:middle}.llms-table.llms-single-course-grades td .llms-status{margin-left:4px}.llms-table.llms-single-course-grades td .llms-donut+.llms-status{margin-right:4px}.llms-table.llms-single-course-grades th.llms-section_title{font-size:110%;font-weight:700}.llms-table.llms-single-course-grades td.llms-lesson_title{padding-right:36px;max-width:40%}.llms-table.llms-single-course-grades td.llms-associated_quiz .llms-donut{display:inline-block;margin-left:5px;vertical-align:middle}.llms-table.llms-single-course-grades td.llms-lesson_title a[href="#"]{pointer-events:none}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"]{color:inherit;position:relative}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"] .llms-tooltip{max-width:380px;width:380px}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"] .llms-tooltip.show{top:-54px}.llms-sd-widgets{display:-webkit-box;display:-ms-flexbox;display:flex}.llms-sd-widgets .llms-sd-widget{background:#f9f9f9;-webkit-box-flex:1;-ms-flex:1;flex:1;margin:10px 10px 20px;padding:0 0 20px}.llms-sd-widgets .llms-sd-widget:first-child{margin-right:0}.llms-sd-widgets .llms-sd-widget:last-child{margin-left:0}.llms-sd-widgets .llms-sd-widget .llms-sd-widget-title{background:#2295ff;color:#fff;font-size:18px;line-height:1;margin:0 0 20px;padding:10px}.llms-sd-widgets .llms-sd-widget .llms-sd-widget-empty{font-size:14px;font-style:italic;opacity:.5;text-align:center}.llms-sd-widgets .llms-sd-widget .llms-donut{margin:0 auto}.llms-sd-widgets .llms-sd-widget .llms-sd-date{opacity:.8;text-align:center;font-size:22px;line-height:1.1}.llms-sd-widgets .llms-sd-widget .llms-sd-date span{display:block}.llms-sd-widgets .llms-sd-widget .llms-sd-date span.day{font-size:52px}.llms-sd-widgets .llms-sd-widget .llms-sd-date span.diff{font-size:12px;font-style:italic;margin-top:8px;opacity:.75}.llms-sd-widgets .llms-sd-widget .llms-achievement{background:rgba(0,0,0,0);margin:0 auto;max-width:120px}.llms-sd-widgets .llms-sd-widget .llms-achievement .llms-achievement-title{display:none}.llms-sd-pagination{margin-top:24px}.llms-sd-pagination:before,.llms-sd-pagination:after{content:" ";display:table}.llms-sd-pagination:after{clear:both}.llms-sd-pagination .llms-button-secondary{display:inline-block}.llms-sd-pagination .llms-button-secondary.prev{float:right}.llms-sd-pagination .llms-button-secondary.next{float:left}.llms-sd-notification-center .llms-notification{z-index:1}.llms-table{border:1px solid #efefef;width:100%}.llms-table thead th,.llms-table thead td{font-weight:700}.llms-table tbody tr:nth-child(odd) td,.llms-table tbody tr:nth-child(odd) th{background:#f9f9f9}.llms-table tbody tr:last-child{border-bottom-width:0}.llms-table tfoot tr{background:#f9f9f9}.llms-table tfoot tr .llms-pagination .page-numbers{margin:0}.llms-table tfoot tr .llms-table-sort{text-align:left}.llms-table tfoot tr .llms-table-sort form,.llms-table tfoot tr .llms-table-sort select,.llms-table tfoot tr .llms-table-sort input,.llms-table tfoot tr .llms-table-sort button{margin:0}.llms-table th{font-weight:700}.llms-table th,.llms-table td{border-bottom:1px solid #efefef;padding:8px 12px}.llms-table th:first-child,.llms-table td:first-child{padding-right:12px}.llms-table th:last-child,.llms-table td:last-child{padding-left:12px}#page .llms-table tfoot label{display:inline}#page .llms-table tfoot select{height:auto}/*! +.llms-pagination ul:before,.llms-pagination ul:after,.llms-student-dashboard .llms-sd-items:before,.llms-form-fields:before,.llms-checkout-cols-2:before,.llms-access-plans:before,.llms-course-navigation:before,.llms-loop-list:before,.llms-cols:before,.llms-student-dashboard .llms-sd-items:after,.llms-form-fields:after,.llms-checkout-cols-2:after,.llms-access-plans:after,.llms-course-navigation:after,.llms-loop-list:after,.llms-cols:after{content:" ";display:table}.llms-pagination ul:after,.llms-student-dashboard .llms-sd-items:after,.llms-form-fields:after,.llms-checkout-cols-2:after,.llms-access-plans:after,.llms-course-navigation:after,.llms-loop-list:after,.llms-cols:after{clear:both}.llms-cols .llms-col{width:100%}@media all and (min-width: 600px){.llms-cols [class*=llms-col-]{float:right}}.llms-flex-cols{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-flow:row wrap;flex-flow:row wrap}.llms-flex-cols [class*=llms-col]{-webkit-box-flex:0;-ms-flex:0 1 auto;flex:0 1 auto;width:100%}@media all and (min-width: 600px){.llms-cols .llms-col-1,.llms-flex-cols .llms-col-1{width:100%}.llms-cols .llms-col-2,.llms-flex-cols .llms-col-2{width:50%}.llms-cols .llms-col-3,.llms-flex-cols .llms-col-3{width:33.3333333333%}.llms-cols .llms-col-4,.llms-flex-cols .llms-col-4{width:25%}.llms-cols .llms-col-5,.llms-flex-cols .llms-col-5{width:20%}.llms-cols .llms-col-6,.llms-flex-cols .llms-col-6{width:16.6666666667%}.llms-cols .llms-col-7,.llms-flex-cols .llms-col-7{width:14.2857142857%}.llms-cols .llms-col-8,.llms-flex-cols .llms-col-8{width:12.5%}.llms-cols .llms-col-9,.llms-flex-cols .llms-col-9{width:11.1111111111%}.llms-cols .llms-col-10,.llms-flex-cols .llms-col-10{width:10%}.llms-cols .llms-col-11,.llms-flex-cols .llms-col-11{width:9.0909090909%}.llms-cols .llms-col-12,.llms-flex-cols .llms-col-12{width:8.3333333333%}}.llms-button-action,.llms-button-danger,.llms-button-primary,.llms-button-secondary{border:none;border-radius:8px;color:#fefefe;cursor:pointer;font-size:16px;font-weight:700;text-decoration:none;text-shadow:none;line-height:1;margin:0;max-width:100%;padding:12px 24px;position:relative;-webkit-transition:all .5s ease;transition:all .5s ease}.llms-button-action:disabled,.llms-button-danger:disabled,.llms-button-primary:disabled,.llms-button-secondary:disabled{opacity:.5}.llms-button-action:hover,.llms-button-action:active,.llms-button-danger:hover,.llms-button-danger:active,.llms-button-primary:hover,.llms-button-primary:active,.llms-button-secondary:hover,.llms-button-secondary:active{color:#fefefe}.llms-button-action:focus,.llms-button-danger:focus,.llms-button-primary:focus,.llms-button-secondary:focus{color:#fefefe}.llms-button-action.auto,.llms-button-danger.auto,.llms-button-primary.auto,.llms-button-secondary.auto{width:auto}.llms-button-action.full,.llms-button-danger.full,.llms-button-primary.full,.llms-button-secondary.full{display:block;text-align:center;width:100%}.llms-button-action.square,.llms-button-danger.square,.llms-button-primary.square,.llms-button-secondary.square{padding:12px}.llms-button-action.small,.llms-button-danger.small,.llms-button-primary.small,.llms-button-secondary.small{font-size:13px;padding:8px 14px}.llms-button-action.small.square,.llms-button-danger.small.square,.llms-button-primary.small.square,.llms-button-secondary.small.square{padding:8px}.llms-button-action.large,.llms-button-danger.large,.llms-button-primary.large,.llms-button-secondary.large{font-size:18px;line-height:1.2;padding:16px 32px}.llms-button-action.large.square,.llms-button-danger.large.square,.llms-button-primary.large.square,.llms-button-secondary.large.square{padding:16px}.llms-button-action.large .fa,.llms-button-danger.large .fa,.llms-button-primary.large .fa,.llms-button-secondary.large .fa{right:-7px;position:relative}.llms-button-primary{background:#2295ff}.llms-button-primary:hover,.llms-button-primary.clicked{background:#0077e4}.llms-button-primary:focus,.llms-button-primary:active{background:#4ba9ff}.llms-button-secondary{background:#e1e1e1;color:#414141}.llms-button-secondary:hover{color:#414141;background:#cdcdcd}.llms-button-secondary:focus,.llms-button-secondary:active{color:#414141;background:#ebebeb}.llms-button-action{background:#f8954f}.llms-button-action:hover,.llms-button-action.clicked{background:#f67d28}.llms-button-action:focus,.llms-button-action:active{background:#faad76}.llms-button-danger{background:#e5554e}.llms-button-danger:hover{background:#e0332a}.llms-button-danger:focus,.llms-button-danger:active{background:#e86660}.llms-button-outline{background:rgba(0,0,0,0);border:3px solid #1d2327;border-radius:8px;color:#1d2327;cursor:pointer;font-size:16px;font-weight:700;text-decoration:none;text-shadow:none;line-height:1;margin:0;max-width:100%;padding:12px 24px;position:relative;-webkit-transition:all .5s ease;transition:all .5s ease}.llms-button-outline:disabled{opacity:.5}.llms-button-outline:hover,.llms-button-outline:active{color:#1d2327}.llms-button-outline:focus{color:#1d2327}.llms-button-outline.auto{width:auto}.llms-button-outline.full{display:block;text-align:center;width:100%}.llms-button-outline.square{padding:12px}.llms-donut{background-color:#f1f1f1;background-image:none;border-radius:50%;color:#ef476f;height:200px;overflow:hidden;position:relative;width:200px}.llms-donut:before,.llms-donut:after{content:" ";display:table}.llms-donut:after{clear:both}.llms-donut svg{overflow:visible !important;pointer-events:none;width:100%}.llms-donut svg path{fill:none;stroke-width:35px;stroke:#ef476f}.llms-donut.mini{height:36px;width:36px}.llms-donut.mini .percentage{font-size:10px}.llms-donut.small{height:100px;width:100px}.llms-donut.small .percentage{font-size:18px}.llms-donut.medium{height:130px;width:130px}.llms-donut.medium .percentage{font-size:26px}.llms-donut.large{height:260px;width:260px}.llms-donut.large .percentage{font-size:48px}.llms-donut .inside{-webkit-box-align:center;-ms-flex-align:center;align-items:center;background:#fff;border-radius:50%;-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;height:80%;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;right:50%;position:absolute;text-align:center;-webkit-transform:translate(50%, -50%);transform:translate(50%, -50%);width:80%;top:50%;z-index:3}.llms-donut .percentage{line-height:1.2;font-size:34px}.llms-donut .caption{font-size:50%}.lifterlms [data-tip],.lifterlms [data-title-default],.lifterlms [data-title-active],.llms-metabox [data-tip],.llms-metabox [data-title-default],.llms-metabox [data-title-active],.llms-mb-container [data-tip],.llms-mb-container [data-title-default],.llms-mb-container [data-title-active],.llms-quiz-wrapper [data-tip],.llms-quiz-wrapper [data-title-default],.llms-quiz-wrapper [data-title-active]{position:relative}.lifterlms [data-tip].tip--top-right:before,.lifterlms [data-title-default].tip--top-right:before,.lifterlms [data-title-active].tip--top-right:before,.llms-metabox [data-tip].tip--top-right:before,.llms-metabox [data-title-default].tip--top-right:before,.llms-metabox [data-title-active].tip--top-right:before,.llms-mb-container [data-tip].tip--top-right:before,.llms-mb-container [data-title-default].tip--top-right:before,.llms-mb-container [data-title-active].tip--top-right:before,.llms-quiz-wrapper [data-tip].tip--top-right:before,.llms-quiz-wrapper [data-title-default].tip--top-right:before,.llms-quiz-wrapper [data-title-active].tip--top-right:before{bottom:100%;right:-10px}.lifterlms [data-tip].tip--top-right:hover:before,.lifterlms [data-title-default].tip--top-right:hover:before,.lifterlms [data-title-active].tip--top-right:hover:before,.llms-metabox [data-tip].tip--top-right:hover:before,.llms-metabox [data-title-default].tip--top-right:hover:before,.llms-metabox [data-title-active].tip--top-right:hover:before,.llms-mb-container [data-tip].tip--top-right:hover:before,.llms-mb-container [data-title-default].tip--top-right:hover:before,.llms-mb-container [data-title-active].tip--top-right:hover:before,.llms-quiz-wrapper [data-tip].tip--top-right:hover:before,.llms-quiz-wrapper [data-title-default].tip--top-right:hover:before,.llms-quiz-wrapper [data-title-active].tip--top-right:hover:before{bottom:calc(100% + 6px)}.lifterlms [data-tip].tip--top-right:after,.lifterlms [data-title-default].tip--top-right:after,.lifterlms [data-title-active].tip--top-right:after,.llms-metabox [data-tip].tip--top-right:after,.llms-metabox [data-title-default].tip--top-right:after,.llms-metabox [data-title-active].tip--top-right:after,.llms-mb-container [data-tip].tip--top-right:after,.llms-mb-container [data-title-default].tip--top-right:after,.llms-mb-container [data-title-active].tip--top-right:after,.llms-quiz-wrapper [data-tip].tip--top-right:after,.llms-quiz-wrapper [data-title-default].tip--top-right:after,.llms-quiz-wrapper [data-title-active].tip--top-right:after{border-top-color:#444;right:6px;top:0}.lifterlms [data-tip].tip--top-right:hover:after,.lifterlms [data-title-default].tip--top-right:hover:after,.lifterlms [data-title-active].tip--top-right:hover:after,.llms-metabox [data-tip].tip--top-right:hover:after,.llms-metabox [data-title-default].tip--top-right:hover:after,.llms-metabox [data-title-active].tip--top-right:hover:after,.llms-mb-container [data-tip].tip--top-right:hover:after,.llms-mb-container [data-title-default].tip--top-right:hover:after,.llms-mb-container [data-title-active].tip--top-right:hover:after,.llms-quiz-wrapper [data-tip].tip--top-right:hover:after,.llms-quiz-wrapper [data-title-default].tip--top-right:hover:after,.llms-quiz-wrapper [data-title-active].tip--top-right:hover:after{top:-6px}.lifterlms [data-tip].tip--top-left:before,.lifterlms [data-title-default].tip--top-left:before,.lifterlms [data-title-active].tip--top-left:before,.llms-metabox [data-tip].tip--top-left:before,.llms-metabox [data-title-default].tip--top-left:before,.llms-metabox [data-title-active].tip--top-left:before,.llms-mb-container [data-tip].tip--top-left:before,.llms-mb-container [data-title-default].tip--top-left:before,.llms-mb-container [data-title-active].tip--top-left:before,.llms-quiz-wrapper [data-tip].tip--top-left:before,.llms-quiz-wrapper [data-title-default].tip--top-left:before,.llms-quiz-wrapper [data-title-active].tip--top-left:before{bottom:100%;left:-10px}.lifterlms [data-tip].tip--top-left:hover:before,.lifterlms [data-title-default].tip--top-left:hover:before,.lifterlms [data-title-active].tip--top-left:hover:before,.llms-metabox [data-tip].tip--top-left:hover:before,.llms-metabox [data-title-default].tip--top-left:hover:before,.llms-metabox [data-title-active].tip--top-left:hover:before,.llms-mb-container [data-tip].tip--top-left:hover:before,.llms-mb-container [data-title-default].tip--top-left:hover:before,.llms-mb-container [data-title-active].tip--top-left:hover:before,.llms-quiz-wrapper [data-tip].tip--top-left:hover:before,.llms-quiz-wrapper [data-title-default].tip--top-left:hover:before,.llms-quiz-wrapper [data-title-active].tip--top-left:hover:before{bottom:calc(100% + 6px)}.lifterlms [data-tip].tip--top-left:after,.lifterlms [data-title-default].tip--top-left:after,.lifterlms [data-title-active].tip--top-left:after,.llms-metabox [data-tip].tip--top-left:after,.llms-metabox [data-title-default].tip--top-left:after,.llms-metabox [data-title-active].tip--top-left:after,.llms-mb-container [data-tip].tip--top-left:after,.llms-mb-container [data-title-default].tip--top-left:after,.llms-mb-container [data-title-active].tip--top-left:after,.llms-quiz-wrapper [data-tip].tip--top-left:after,.llms-quiz-wrapper [data-title-default].tip--top-left:after,.llms-quiz-wrapper [data-title-active].tip--top-left:after{border-top-color:#444;left:6px;top:0}.lifterlms [data-tip].tip--top-left:hover:after,.lifterlms [data-title-default].tip--top-left:hover:after,.lifterlms [data-title-active].tip--top-left:hover:after,.llms-metabox [data-tip].tip--top-left:hover:after,.llms-metabox [data-title-default].tip--top-left:hover:after,.llms-metabox [data-title-active].tip--top-left:hover:after,.llms-mb-container [data-tip].tip--top-left:hover:after,.llms-mb-container [data-title-default].tip--top-left:hover:after,.llms-mb-container [data-title-active].tip--top-left:hover:after,.llms-quiz-wrapper [data-tip].tip--top-left:hover:after,.llms-quiz-wrapper [data-title-default].tip--top-left:hover:after,.llms-quiz-wrapper [data-title-active].tip--top-left:hover:after{top:-6px}.lifterlms [data-tip].tip--bottom-left:before,.lifterlms [data-title-default].tip--bottom-left:before,.lifterlms [data-title-active].tip--bottom-left:before,.llms-metabox [data-tip].tip--bottom-left:before,.llms-metabox [data-title-default].tip--bottom-left:before,.llms-metabox [data-title-active].tip--bottom-left:before,.llms-mb-container [data-tip].tip--bottom-left:before,.llms-mb-container [data-title-default].tip--bottom-left:before,.llms-mb-container [data-title-active].tip--bottom-left:before,.llms-quiz-wrapper [data-tip].tip--bottom-left:before,.llms-quiz-wrapper [data-title-default].tip--bottom-left:before,.llms-quiz-wrapper [data-title-active].tip--bottom-left:before{top:100%;left:-10px}.lifterlms [data-tip].tip--bottom-left:hover:before,.lifterlms [data-title-default].tip--bottom-left:hover:before,.lifterlms [data-title-active].tip--bottom-left:hover:before,.llms-metabox [data-tip].tip--bottom-left:hover:before,.llms-metabox [data-title-default].tip--bottom-left:hover:before,.llms-metabox [data-title-active].tip--bottom-left:hover:before,.llms-mb-container [data-tip].tip--bottom-left:hover:before,.llms-mb-container [data-title-default].tip--bottom-left:hover:before,.llms-mb-container [data-title-active].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-tip].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-title-default].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-title-active].tip--bottom-left:hover:before{top:calc(100% + 6px)}.lifterlms [data-tip].tip--bottom-left:after,.lifterlms [data-title-default].tip--bottom-left:after,.lifterlms [data-title-active].tip--bottom-left:after,.llms-metabox [data-tip].tip--bottom-left:after,.llms-metabox [data-title-default].tip--bottom-left:after,.llms-metabox [data-title-active].tip--bottom-left:after,.llms-mb-container [data-tip].tip--bottom-left:after,.llms-mb-container [data-title-default].tip--bottom-left:after,.llms-mb-container [data-title-active].tip--bottom-left:after,.llms-quiz-wrapper [data-tip].tip--bottom-left:after,.llms-quiz-wrapper [data-title-default].tip--bottom-left:after,.llms-quiz-wrapper [data-title-active].tip--bottom-left:after{border-bottom-color:#444;left:6px;bottom:0}.lifterlms [data-tip].tip--bottom-left:hover:after,.lifterlms [data-title-default].tip--bottom-left:hover:after,.lifterlms [data-title-active].tip--bottom-left:hover:after,.llms-metabox [data-tip].tip--bottom-left:hover:after,.llms-metabox [data-title-default].tip--bottom-left:hover:after,.llms-metabox [data-title-active].tip--bottom-left:hover:after,.llms-mb-container [data-tip].tip--bottom-left:hover:after,.llms-mb-container [data-title-default].tip--bottom-left:hover:after,.llms-mb-container [data-title-active].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-tip].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-title-default].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-title-active].tip--bottom-left:hover:after{bottom:-6px}.lifterlms [data-tip].tip--bottom-right:before,.lifterlms [data-title-default].tip--bottom-right:before,.lifterlms [data-title-active].tip--bottom-right:before,.llms-metabox [data-tip].tip--bottom-right:before,.llms-metabox [data-title-default].tip--bottom-right:before,.llms-metabox [data-title-active].tip--bottom-right:before,.llms-mb-container [data-tip].tip--bottom-right:before,.llms-mb-container [data-title-default].tip--bottom-right:before,.llms-mb-container [data-title-active].tip--bottom-right:before,.llms-quiz-wrapper [data-tip].tip--bottom-right:before,.llms-quiz-wrapper [data-title-default].tip--bottom-right:before,.llms-quiz-wrapper [data-title-active].tip--bottom-right:before{top:100%;right:-10px}.lifterlms [data-tip].tip--bottom-right:hover:before,.lifterlms [data-title-default].tip--bottom-right:hover:before,.lifterlms [data-title-active].tip--bottom-right:hover:before,.llms-metabox [data-tip].tip--bottom-right:hover:before,.llms-metabox [data-title-default].tip--bottom-right:hover:before,.llms-metabox [data-title-active].tip--bottom-right:hover:before,.llms-mb-container [data-tip].tip--bottom-right:hover:before,.llms-mb-container [data-title-default].tip--bottom-right:hover:before,.llms-mb-container [data-title-active].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-tip].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-title-default].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-title-active].tip--bottom-right:hover:before{top:calc(100% + 6px)}.lifterlms [data-tip].tip--bottom-right:after,.lifterlms [data-title-default].tip--bottom-right:after,.lifterlms [data-title-active].tip--bottom-right:after,.llms-metabox [data-tip].tip--bottom-right:after,.llms-metabox [data-title-default].tip--bottom-right:after,.llms-metabox [data-title-active].tip--bottom-right:after,.llms-mb-container [data-tip].tip--bottom-right:after,.llms-mb-container [data-title-default].tip--bottom-right:after,.llms-mb-container [data-title-active].tip--bottom-right:after,.llms-quiz-wrapper [data-tip].tip--bottom-right:after,.llms-quiz-wrapper [data-title-default].tip--bottom-right:after,.llms-quiz-wrapper [data-title-active].tip--bottom-right:after{border-bottom-color:#444;right:6px;bottom:0}.lifterlms [data-tip].tip--bottom-right:hover:after,.lifterlms [data-title-default].tip--bottom-right:hover:after,.lifterlms [data-title-active].tip--bottom-right:hover:after,.llms-metabox [data-tip].tip--bottom-right:hover:after,.llms-metabox [data-title-default].tip--bottom-right:hover:after,.llms-metabox [data-title-active].tip--bottom-right:hover:after,.llms-mb-container [data-tip].tip--bottom-right:hover:after,.llms-mb-container [data-title-default].tip--bottom-right:hover:after,.llms-mb-container [data-title-active].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-tip].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-title-default].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-title-active].tip--bottom-right:hover:after{bottom:-6px}.lifterlms [data-tip]:before,.lifterlms [data-title-default]:before,.lifterlms [data-title-active]:before,.llms-metabox [data-tip]:before,.llms-metabox [data-title-default]:before,.llms-metabox [data-title-active]:before,.llms-mb-container [data-tip]:before,.llms-mb-container [data-title-default]:before,.llms-mb-container [data-title-active]:before,.llms-quiz-wrapper [data-tip]:before,.llms-quiz-wrapper [data-title-default]:before,.llms-quiz-wrapper [data-title-active]:before{background:#444;border-radius:4px;color:#fff;font-size:13px;line-height:1.2;padding:8px;max-width:300px;width:-webkit-max-content;width:-moz-max-content;width:max-content}.lifterlms [data-tip]:after,.lifterlms [data-title-default]:after,.lifterlms [data-title-active]:after,.llms-metabox [data-tip]:after,.llms-metabox [data-title-default]:after,.llms-metabox [data-title-active]:after,.llms-mb-container [data-tip]:after,.llms-mb-container [data-title-default]:after,.llms-mb-container [data-title-active]:after,.llms-quiz-wrapper [data-tip]:after,.llms-quiz-wrapper [data-title-default]:after,.llms-quiz-wrapper [data-title-active]:after{content:"";border:6px solid rgba(0,0,0,0);height:0;width:0}.lifterlms [data-tip]:before,.lifterlms [data-tip]:after,.lifterlms [data-title-default]:before,.lifterlms [data-title-default]:after,.lifterlms [data-title-active]:before,.lifterlms [data-title-active]:after,.llms-metabox [data-tip]:before,.llms-metabox [data-tip]:after,.llms-metabox [data-title-default]:before,.llms-metabox [data-title-default]:after,.llms-metabox [data-title-active]:before,.llms-metabox [data-title-active]:after,.llms-mb-container [data-tip]:before,.llms-mb-container [data-tip]:after,.llms-mb-container [data-title-default]:before,.llms-mb-container [data-title-default]:after,.llms-mb-container [data-title-active]:before,.llms-mb-container [data-title-active]:after,.llms-quiz-wrapper [data-tip]:before,.llms-quiz-wrapper [data-tip]:after,.llms-quiz-wrapper [data-title-default]:before,.llms-quiz-wrapper [data-title-default]:after,.llms-quiz-wrapper [data-title-active]:before,.llms-quiz-wrapper [data-title-active]:after{opacity:0;-webkit-transition:all .2s .1s ease;transition:all .2s .1s ease;position:absolute;pointer-events:none;visibility:hidden}.lifterlms [data-tip]:hover:before,.lifterlms [data-tip]:hover:after,.lifterlms [data-title-default]:hover:before,.lifterlms [data-title-default]:hover:after,.lifterlms [data-title-active]:hover:before,.lifterlms [data-title-active]:hover:after,.llms-metabox [data-tip]:hover:before,.llms-metabox [data-tip]:hover:after,.llms-metabox [data-title-default]:hover:before,.llms-metabox [data-title-default]:hover:after,.llms-metabox [data-title-active]:hover:before,.llms-metabox [data-title-active]:hover:after,.llms-mb-container [data-tip]:hover:before,.llms-mb-container [data-tip]:hover:after,.llms-mb-container [data-title-default]:hover:before,.llms-mb-container [data-title-default]:hover:after,.llms-mb-container [data-title-active]:hover:before,.llms-mb-container [data-title-active]:hover:after,.llms-quiz-wrapper [data-tip]:hover:before,.llms-quiz-wrapper [data-tip]:hover:after,.llms-quiz-wrapper [data-title-default]:hover:before,.llms-quiz-wrapper [data-title-default]:hover:after,.llms-quiz-wrapper [data-title-active]:hover:before,.llms-quiz-wrapper [data-title-active]:hover:after{opacity:1;-webkit-transition:all .2s .6s ease;transition:all .2s .6s ease;visibility:visible;z-index:99999999}.lifterlms [data-tip]:before,.llms-metabox [data-tip]:before,.llms-mb-container [data-tip]:before,.llms-quiz-wrapper [data-tip]:before{content:attr(data-tip)}.lifterlms [data-tip].active:before,.llms-metabox [data-tip].active:before,.llms-mb-container [data-tip].active:before,.llms-quiz-wrapper [data-tip].active:before{content:attr(data-tip-active)}.llms-membership-image{display:block;margin:0 auto}.llms-course-image{display:block;margin:0 auto;max-width:100%}.llms-featured-image{display:block;margin:0 auto}.llms-image-thumb{width:150px}.llms-video-wrapper .center-video{height:auto;max-width:100%;overflow:hidden;position:relative;padding-top:56.25%;text-align:center}.llms-video-wrapper .center-video>.wp-video,.llms-video-wrapper .center-video .fluid-width-video-wrapper,.llms-video-wrapper .center-video iframe,.llms-video-wrapper .center-video object,.llms-video-wrapper .center-video embed{height:100%;right:0;position:absolute;top:0;width:100%}.llms-video-wrapper .center-video>.wp-video{width:100% !important}.llms-video-wrapper .center-video .fluid-width-video-wrapper{padding-top:0 !important}.clear{clear:both;width:100%}.llms-featured-image{text-align:center}#main-content .llms-payment-options p{margin:0;font-size:16px}.llms-option{display:block;position:relative;margin:20px 0;padding-right:40px;font-size:16px}.llms-option label{cursor:pointer;position:static}.llms-option:first-child{margin-top:0}.llms-option:last-child{margin-bottom:0}#main-content .llms-option:last-child{margin-bottom:0}.llms-option input[type=radio]{display:block;position:absolute;top:3px;right:0;z-index:0}.llms-option input[type=radio]{display:inline-block}.llms-option input[type=radio]+label span.llms-radio{display:none}.llms-option input[type=radio]+label span.llms-radio{-webkit-appearance:none;-moz-appearance:none;appearance:none;z-index:20;position:absolute;top:0;right:-2px;display:inline-block;width:24px;height:24px;border-radius:50%;cursor:pointer;vertical-align:middle;-webkit-box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.5) 0 0 0 1px;box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.5) 0 0 0 1px;background:#efefef;background-image:radial-gradient(ellipse at center, #e5554e 0%, #e5554e 40%, #efefef 45%);background-repeat:no-repeat;-webkit-transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);transition:background-position .15s cubic-bezier(0.8, 0, 1, 1)}.llms-option input[type=radio]:checked+label span.llms-radio{-webkit-transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1)}.llms-option input[type=radio]+label span.llms-radio{background-position:-24px 0}.llms-option input[type=radio]:checked+label span.llms-radio{background-position:100% 0}.llms-option input[type=submit]{border:none;background:#e5554e;color:#fff;font-size:20px;padding:10px 0;border-radius:3px;cursor:pointer;width:100%}.llms-styled-text{padding:14px 0}.llms-notice-box{border-radius:3px;z-index:10;margin:10px 0;padding:15px 20px;border:1px solid #ccc;list-style-type:none;width:100%;overflow:auto}.llms-notice-box input[type=text]{height:auto}.llms-notice-box .col-1-1{width:100%}.llms-notice-box .col-1-1 input[type=text]{width:100%}.llms-notice-box .col-1-2{width:50%;float:right}@media screen and (max-width: 768px){.llms-notice-box .col-1-2{width:100%}}.llms-notice-box .col-1-3{width:33%;float:right;margin-left:10px}.llms-notice-box .col-1-4{width:25%;float:right;margin-left:10px}@media screen and (max-width: 768px){.llms-notice-box .col-1-4{width:100%}}.llms-notice-box .col-1-6{width:16.6%;float:right;margin-left:10px}.llms-notice-box .col-1-8{width:11%;float:left}.llms-notice-box .llms-pad-right{padding-left:10px}@media screen and (max-width: 768px){.llms-notice-box .llms-pad-right{padding-left:0}}input[type=text].cc_cvv,#cc_cvv{margin-left:0;width:23%;float:left}.llms-clear-box{border-radius:3px;z-index:10;margin:10px 0;padding:15px 20px;list-style-type:none;width:100%;overflow:auto}.llms-price-label{font-weight:normal}.llms-final-price{font-weight:bold;float:left}.llms-center-content{text-align:center}.llms-input-text{background-color:#fff;border:1px solid #ddd;color:#333;font-size:18px;font-weight:300;padding:16px;width:100%}.llms-price{margin-bottom:0;font-weight:bold}.llms-price-loop{margin-bottom:0;font-weight:bold}.courses .entry{padding:0}.list-view .site-content .llms-course-list .hentry,.list-view .site-content .llms-membership-list .hentry{border-top:0;padding-top:0}.llms-content{width:100%}.llms-lesson-button-wrapper{width:100%;display:block;clear:both;text-align:center}.llms-template-wrapper{width:100%;display:block;clear:both}.llms-button-wrapper{width:100%;display:block;clear:both;text-align:center}.llms-styled-select{border:1px solid #ccc;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:3px;overflow:hidden;position:relative}.llms-styled-select,.llms-styled-select select{width:100%}select:focus{outline:none}.llms-styled-select select{height:34px;padding:5px 5px 5px 0;background:rgba(0,0,0,0);border:none;-webkit-appearance:none;font-size:16px;color:#444}@-moz-document url-prefix(){.--ms-styled-select select{width:110%}}.llms-styled-select .fa-sort-desc{position:absolute;top:0;left:12px;font-size:24px;color:#ccc}select::-ms-expand{display:none}_:-o-prefocus .llms-styled-select,.selector .llms-styled-select{background:none}.llms-form-item-wrapper{margin-bottom:1em}.llms-progress-circle{position:relative;width:200px;height:200px;float:right}.llms-progress-circle-count{top:27%;position:absolute;width:94%;text-align:center;color:#666;font-size:44px}.llms-progress-circle svg{position:absolute;width:200px;height:200px}.llms-progress-circle circle{fill:rgba(0,0,0,0)}svg .llms-background-circle{fill:rgba(0,0,0,0);stroke-width:10px;stroke:#f1f2f1;stroke-dasharray:430}svg .llms-animated-circle{fill:rgba(0,0,0,0);stroke-width:10px;stroke:#e5554e;stroke-dasharray:430;stroke-dashoffset:410}.llms-widget-syllabus .llms-lesson.current-lesson .lesson-title{font-weight:700}.llms-widget-syllabus .llms-lesson-complete,.llms-widget-syllabus .lesson-complete-placeholder{font-size:1.2em;margin-left:6px;color:#ccc}.llms-widget-syllabus .llms-lesson-complete.done,.llms-widget-syllabus .lesson-complete-placeholder.done{color:#e5554e}.llms-widget-syllabus .section-title{font-weight:bold}.llms-widget-syllabus .lesson-title a{text-decoration:none}.llms-widget-syllabus .lesson-title a:hover{text-decoration:none !important}.llms-widget-syllabus .lesson-title.done a{color:#999;text-decoration:line-through}.llms-widget-syllabus ul{list-style-type:none}.llms-widget-syllabus ul li{list-style-type:none}.llms-widget-syllabus ul li ul li{margin:0 0 2px 0;padding:0}.llms-remove-coupon{float:left}.llms-lesson-link-locked,.llms-lesson-link-locked:hover{background:#f1f1f1;-webkit-box-shadow:0 1px 2px 0 rgba(1,1,1,.4);box-shadow:0 1px 2px 0 rgba(1,1,1,.4);display:block;color:#a6a6a6;min-height:85px;padding:15px;text-decoration:none;position:relative}.llms-lesson-preview.is-complete .llms-lesson-link-locked{padding-right:75px}.llms-lesson-tooltip{display:none;position:absolute;color:#000;background-color:silver;padding:.25em;border-radius:2px;z-index:100;top:0;right:50%;text-align:center;-webkit-transform:translateX(50%) translateY(-100%);transform:translateX(50%) translateY(-100%)}.llms-lesson-tooltip:after{content:"";width:0;height:0;border-top:8px solid silver;border-right:8px solid rgba(0,0,0,0);border-left:8px solid rgba(0,0,0,0);position:absolute;bottom:-8px;right:50%;-webkit-transform:translateX(50%);transform:translateX(50%)}.llms-lesson-tooltip.active{display:inline-block}.llms-favorite-wrapper{cursor:pointer}.llms-favorite-wrapper .fa-heart{color:#ef476f}.llms-has-favorite .llms-parent-course-link{display:inline-block;margin-bottom:20px}.llms-has-favorite .llms-parent-course-link+.llms-favorite-wrapper{float:left;margin:0}.llms-syllabus-wrapper .llms-has-favorite{text-align:right}.llms-syllabus-wrapper .llms-has-favorite .llms-favorite-wrapper{display:inline-block}.llms-loop-list{list-style:none;margin:0 -10px;padding:0}@media all and (min-width: 600px){.llms-loop-list.cols-1 .llms-loop-item{width:100%}.llms-loop-list.cols-2 .llms-loop-item{width:50%}.llms-loop-list.cols-3 .llms-loop-item{width:33.3333333333%}.llms-loop-list.cols-4 .llms-loop-item{width:25%}.llms-loop-list.cols-5 .llms-loop-item{width:20%}.llms-loop-list.cols-6 .llms-loop-item{width:16.6666666667%}}.llms-loop-item{float:right;list-style:none;margin:0;padding:0;width:100%}.llms-loop-item-content{background:#f1f1f1;padding-bottom:10px;margin:10px}.llms-loop-item-content:hover{background:#eaeaea}.llms-loop-item-content .llms-loop-link{color:#212121;display:block}.llms-loop-item-content .llms-loop-link:visited{color:#212121}.llms-loop-item-content .llms-featured-image{display:block;max-width:100%}.llms-loop-item-content .llms-loop-title{margin-top:5px}.llms-loop-item-content .llms-loop-title:hover{color:#2295ff}.llms-loop-item-content .llms-meta,.llms-loop-item-content .llms-author,.llms-loop-item-content .llms-loop-title{padding:0 10px}.llms-loop-item-content .llms-meta,.llms-loop-item-content .llms-author{color:#444;display:block;font-size:13px;margin-bottom:3px}.llms-loop-item-content .llms-meta:last-child,.llms-loop-item-content .llms-author:last-child{margin-bottom:0}.llms-loop-item-content .llms-featured-img-wrap{overflow:hidden}.llms-loop-item-content p{margin-bottom:0}.llms-loop-item-content .llms-progress{margin:0;height:.4em}.llms-loop-item-content .llms-progress .progress__indicator{display:none}.llms-loop-item-content .llms-progress .llms-progress-bar{background-color:#f6f6f6;left:0;top:0}.course .llms-meta-info{margin:20px 0}.course .llms-meta-info .llms-meta-title{margin-bottom:5px}.course .llms-meta-info .llms-meta p{margin-bottom:0}.course .llms-meta-info .llms-meta span{font-weight:700}.course .llms-course-progress{margin:40px auto;max-width:480px;text-align:center}.llms-syllabus-wrapper{margin:15px;text-align:center}.llms-syllabus-wrapper .llms-section-title{margin:25px 0 0}.llms-course-navigation .llms-prev-lesson,.llms-course-navigation .llms-next-lesson,.llms-course-navigation .llms-back-to-course{width:49%}.llms-course-navigation .llms-prev-lesson,.llms-course-navigation .llms-back-to-course{float:right;margin-left:.5%}.llms-course-navigation .llms-next-lesson,.llms-course-navigation .llms-prev-lesson+.llms-back-to-course{float:left;margin-right:.5%}.llms-lesson-preview{display:inline-block;margin-top:15px;max-width:100%;position:relative;width:480px}.llms-lesson-preview .llms-lesson-link{background:#f1f1f1;color:#212121;display:block;padding:15px;text-decoration:none}.llms-lesson-preview .llms-lesson-link:before,.llms-lesson-preview .llms-lesson-link:after{content:" ";display:table}.llms-lesson-preview .llms-lesson-link:after{clear:both}.llms-lesson-preview .llms-lesson-link:hover{background:#eaeaea}.llms-lesson-preview .llms-lesson-link:visited{color:#212121}.llms-lesson-preview .llms-lesson-thumbnail{margin-bottom:10px}.llms-lesson-preview .llms-lesson-thumbnail img{display:block;width:100%}.llms-lesson-preview .llms-pre-text{text-align:right}.llms-lesson-preview .llms-lesson-title{font-weight:700;margin:0 auto 10px;text-align:right}.llms-lesson-preview .llms-lesson-title:last-child{margin-bottom:0}.llms-lesson-preview .llms-lesson-excerpt{text-align:right}.llms-lesson-preview .llms-main{float:right;width:100%}.llms-lesson-preview .llms-extra{float:left;width:15%}.llms-lesson-preview .llms-extra+.llms-main{width:85%}.llms-lesson-preview .llms-lesson-counter,.llms-lesson-preview .llms-free-lesson-svg,.llms-lesson-preview .llms-lesson-complete,.llms-lesson-preview .llms-lesson-complete-placeholder{display:block;font-size:32px;margin-bottom:15px}.llms-lesson-preview.is-free .llms-lesson-complete,.llms-lesson-preview.is-complete .llms-lesson-complete{color:#2295ff}.llms-lesson-preview .llms-icon-free{background:#2295ff;border-radius:4px;color:#f1f1f1;display:inline-block;padding:5px 6px 4px;line-height:1;font-size:14px}.llms-lesson-preview.is-incomplete .llms-lesson-complete{color:#cacaca}.llms-lesson-preview .llms-lesson-counter{font-size:16px;line-height:1}.llms-lesson-preview .llms-free-lesson-svg{fill:currentColor;height:23px;width:50px}.llms-lesson-preview p{margin-bottom:0}.llms-progress{clear:both;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:reverse;-ms-flex-direction:row-reverse;flex-direction:row-reverse;position:relative;height:1em;width:100%;margin:15px 0}.llms-progress .llms-progress-bar{background-color:#f1f2f1;position:relative;height:.4em;top:.3em;width:100%}.llms-progress .progress-bar-complete{background-color:#ef476f;height:100%}.progress__indicator{float:left;text-align:left;height:1em;line-height:1em;margin-right:5px;white-space:nowrap}.llms-author .name{margin-right:5px}.llms-author .label{margin-right:5px}.llms-author .avatar{border-radius:50%}.llms-author .bio{margin-top:5px}.llms-instructor-info .llms-instructors .llms-col:first-child .llms-author{margin-right:0}.llms-instructor-info .llms-instructors .llms-col:last-child .llms-author{margin-left:0}.llms-instructor-info .llms-instructors .llms-author{background:#f5f5f5;border-top:4px solid #2295ff;text-align:center;margin:45px 5px 5px;padding:0 10px 10px}.llms-instructor-info .llms-instructors .llms-author .avatar{background:#2295ff;border:4px solid #2295ff;display:block;margin:-35px auto 10px}.llms-instructor-info .llms-instructors .llms-author .llms-author-info{display:block}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.name{font-weight:700}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.label{font-size:85%}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.bio{font-size:90%;margin-bottom:0}.llms_review{margin:20px 0px;padding:10px}.llms_review h5{font-size:17px;margin:3px 0px}.llms_review h6{font-size:13px}.llms_review p{font-size:15px}.review_box [type=text]{margin:10px 0px}.review_box h5{color:red;display:none}.review_box+.thank_you_box{display:none}.llms-notice{background:rgba(34,149,255,.3);border-color:#2295ff;border-style:solid;border-width:3px;padding:10px;margin-bottom:10px}.llms-notice p:last-child,.llms-notice ul:last-child{margin-bottom:0}.llms-notice li{list-style-type:none}.llms-notice.llms-debug{background:rgba(202,202,202,.3);border-color:#cacaca}.llms-notice.llms-error{background:rgba(229,85,78,.3);border-color:#e5554e}.llms-notice.llms-success{background:rgba(131,195,115,.3);border-color:#83c373}.entry-content .llms-notice{margin:0 0 10px}.entry-content .llms-notice li{list-style-type:none}ul.llms-achievements-loop,.lifterlms ul.llms-achievements-loop,ul.llms-certificates-loop,.lifterlms ul.llms-certificates-loop{list-style-type:none;margin:0 -10px;padding:0}ul.llms-achievements-loop:before,ul.llms-achievements-loop:after,.lifterlms ul.llms-achievements-loop:before,.lifterlms ul.llms-achievements-loop:after,ul.llms-certificates-loop:before,ul.llms-certificates-loop:after,.lifterlms ul.llms-certificates-loop:before,.lifterlms ul.llms-certificates-loop:after{content:" ";display:table}ul.llms-achievements-loop:after,.lifterlms ul.llms-achievements-loop:after,ul.llms-certificates-loop:after,.lifterlms ul.llms-certificates-loop:after{clear:both}ul.llms-achievements-loop li.llms-achievement-loop-item,ul.llms-achievements-loop li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop li.llms-certificate-loop-item,ul.llms-certificates-loop li.llms-achievement-loop-item,ul.llms-certificates-loop li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop li.llms-certificate-loop-item{-webkit-box-sizing:border-box;box-sizing:border-box;display:block;float:right;list-style-type:none;margin:0;padding:10px;width:100%}@media all and (min-width: 600px){ul.llms-achievements-loop.loop-cols-1 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-1 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-1 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-1 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-1 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-1 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-1 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-1 li.llms-certificate-loop-item{width:100%}ul.llms-achievements-loop.loop-cols-2 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-2 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-2 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-2 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-2 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-2 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-2 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-2 li.llms-certificate-loop-item{width:50%}ul.llms-achievements-loop.loop-cols-3 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-3 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-3 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-3 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-3 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-3 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-3 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-3 li.llms-certificate-loop-item{width:33.3333333333%}ul.llms-achievements-loop.loop-cols-4 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-4 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-4 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-4 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-4 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-4 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-4 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-4 li.llms-certificate-loop-item{width:25%}ul.llms-achievements-loop.loop-cols-5 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-5 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-5 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-5 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-5 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-5 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-5 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-5 li.llms-certificate-loop-item{width:20%}}.llms-achievement,.llms-certificate{background:#f1f1f1;border:none;color:inherit;display:block;text-decoration:none;width:100%}.llms-achievement:hover,.llms-certificate:hover{background:#eaeaea}.llms-achievement .llms-achievement-img,.llms-certificate .llms-achievement-img{display:block;margin:0;width:100%}.llms-achievement .llms-achievement-title,.llms-certificate .llms-achievement-title{font-size:16px;margin:0;padding:10px;text-align:center}.llms-achievement .llms-certificate-title,.llms-certificate .llms-certificate-title{font-size:16px;margin:0;padding:0 0 10px}.llms-achievement .llms-achievement-info,.llms-achievement .llms-achievement-date,.llms-certificate .llms-achievement-info,.llms-certificate .llms-achievement-date{display:none}.llms-achievement .llms-achievement-content,.llms-certificate .llms-achievement-content{padding:20px}.llms-achievement .llms-achievement-content:empty,.llms-certificate .llms-achievement-content:empty{padding:0}.llms-achievement .llms-achievement-content *:last-child,.llms-certificate .llms-achievement-content *:last-child{margin-bottom:0}.llms-certificate{border:4px double #f1f1f1;padding:20px 10px;background:#fff;text-align:center}.llms-certificate:hover{background:#fff;border-color:#eaeaea}.llms-achievement-modal .llms-achievement{background:#fff}.llms-achievement-modal .llms-achievement-info{display:block}.llms-achievement-modal .llms-achievement-title{display:none}.llms-notification{background:#fff;-webkit-box-shadow:0 1px 2px -2px #333,0 1px 1px -1px #333;box-shadow:0 1px 2px -2px #333,0 1px 1px -1px #333;border-top:4px solid #2295ff;opacity:0;padding:12px;position:fixed;left:-800px;top:24px;-webkit-transition:opacity .4s ease-in-out,left .4s ease-in-out;transition:opacity .4s ease-in-out,left .4s ease-in-out;visibility:hidden;width:auto;z-index:9999999}.llms-notification:before,.llms-notification:after{content:" ";display:table}.llms-notification:after{clear:both}.llms-notification.visible{right:12px;opacity:1;left:12px;-webkit-transition:opacity .4s ease-in-out,left .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,-webkit-transform .2s ease-in-out;transition:opacity .4s ease-in-out,left .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,-webkit-transform .2s ease-in-out;transition:opacity .4s ease-in-out,left .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,transform .2s ease-in-out;transition:opacity .4s ease-in-out,left .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,transform .2s ease-in-out,-webkit-transform .2s ease-in-out;visibility:visible}.llms-notification.visible:hover .llms-notification-dismiss{opacity:1}.llms-notification .llms-notification-content{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex}.llms-notification .llms-notification-main{-ms-flex-item-align:start;align-self:flex-start;-webkit-box-flex:4;-ms-flex:4;flex:4;-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2}.llms-notification .llms-notification-title{font-size:18px;margin:0}.llms-notification .llms-notification-body{font-size:14px;line-height:1.4}.llms-notification .llms-notification-body p,.llms-notification .llms-notification-body li{font-size:inherit}.llms-notification .llms-notification-body p{margin-bottom:8px}.llms-notification .llms-notification-body .llms-mini-cert{background:#f6f6f6;border:1px solid #d0d0d0;-webkit-box-shadow:inset 0 0 0 3px #fefefe,inset 0 0 0 4px #dedede;box-shadow:inset 0 0 0 3px #fefefe,inset 0 0 0 4px #dedede;padding:16px 16px 24px;margin-top:12px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert-title{font-size:16px;font-weight:700;margin:12px auto;text-align:center}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body{width:100%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(1){width:65%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(2){width:35%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(3){width:85%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(4){width:75%;margin-top:18px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(5){width:70%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(6){margin-right:12px;margin-bottom:-24px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(7){width:65%;margin-left:12px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--mock-line{border-radius:2px;height:8px;background:#b0b0b0;background-image:-webkit-gradient(linear, right top, left top, from(#b0b0b0), color-stop(20%, #a0a0a0), color-stop(40%, #b0b0b0), to(#b0b0b0));background-image:linear-gradient(to left, #b0b0b0 0%, #a0a0a0 20%, #b0b0b0 40%, #b0b0b0 100%);background-repeat:no-repeat;margin:4px auto}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--mock-dot{background:#b0b0b0;border-radius:50%;display:inline-block;content:"";height:24px;width:24px}.llms-notification .llms-notification-body .llms-mini-cert p{margin-bottom:0}.llms-notification .llms-notification-aside{-ms-flex-item-align:start;align-self:flex-start;-webkit-box-flex:1;-ms-flex:1;flex:1;margin-left:12px;-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1}.llms-notification .llms-notification-icon{display:block;max-width:64px}.llms-notification .llms-notification-footer{border-top:1px solid #e5e5e5;font-size:12px;margin-top:12px;padding:6px 6px 0;text-align:left}.llms-notification .llms-notification-dismiss{color:#e5554e;cursor:pointer;font-size:22px;position:absolute;left:10px;top:8px;-webkit-transition:opacity .4s ease-in-out;transition:opacity .4s ease-in-out}.llms-sd-notification-center .llms-notification-list,.llms-sd-notification-center .llms-notification-list-item{list-style-type:none;margin:0;padding:0}.llms-sd-notification-center .llms-notification-list-item:hover .llms-notification{background:#fcfcfc}.llms-sd-notification-center .llms-notification{opacity:1;border-top:1px solid #e5e5e5;right:auto;padding:24px;position:relative;left:auto;top:auto;visibility:visible;width:auto}.llms-sd-notification-center .llms-notification .llms-notification-aside{max-width:64px}.llms-sd-notification-center .llms-notification .llms-notification-footer{border:none;padding:0;text-align:right}.llms-sd-notification-center .llms-notification .llms-progress{display:none !important}.llms-sd-notification-center .llms-notification .llms-notification-date{color:#515151;float:right;margin-left:6px}.llms-sd-notification-center .llms-notification .llms-mini-cert{margin:0 auto;max-width:380px}@media all and (min-width: 480px){.llms-notification{left:-800px;width:360px}.llms-notification.visible{right:auto;left:24px}.llms-notification .llms-notification-dismiss{opacity:0}}.llms-pagination ul{list-style-type:none}.llms-pagination ul li{float:right}.llms-pagination ul li a{border-bottom:0;text-decoration:none}.llms-pagination ul li .page-numbers{padding:.5em;text-decoration:underline}.llms-pagination ul li .page-numbers.current{text-decoration:none}.llms-tooltip{background:#2a2a2a;border-radius:4px;color:#fff;font-size:14px;line-height:1.2;opacity:0;top:-20px;padding:8px 12px;right:50%;position:absolute;pointer-events:none;-webkit-transform:translateX(50%);transform:translateX(50%);-webkit-transition:opacity .2s ease,top .2s ease;transition:opacity .2s ease,top .2s ease;max-width:320px}.llms-tooltip.show{top:-28px;opacity:1}.llms-tooltip:after{bottom:-8px;border-top:8px solid #2a2a2a;border-right:8px solid rgba(0,0,0,0);border-left:8px solid rgba(0,0,0,0);content:"";height:0;right:50%;position:absolute;-webkit-transform:translateX(50%);transform:translateX(50%);width:0}.webui-popover-title{font-size:initial;font-weight:initial;line-height:initial}.webui-popover-inverse .webui-popover-inner .close{color:#fff;opacity:.6;text-shadow:none}.webui-popover-inverse .webui-popover-inner .close:hover{opacity:.8}.webui-popover-inverse .webui-popover-content a{color:#fff;text-decoration:underline}.webui-popover-inverse .webui-popover-content a:hover{text-decoration:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results{margin:0;padding:0;list-style-type:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question{background:#efefef;margin:0 0 10px;position:relative;list-style-type:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer{color:inherit;display:block;padding:10px 10px 10px 35px;text-decoration:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:before,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:after{content:" ";display:table}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:after{clear:both}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.correct,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.incorrect{background:rgba(255,146,43,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.correct .llms-status-icon,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.incorrect .llms-status-icon{background-color:#ff922b}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.correct{background:rgba(131,195,115,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.correct .llms-status-icon{background-color:#83c373}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.incorrect{background:rgba(229,85,78,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.incorrect .llms-status-icon{background-color:#e5554e}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question pre{overflow:auto}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-question-title{float:right;margin:0;line-height:1}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-points{float:left;line-height:1}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-status-icon-tip{position:absolute;left:-12px;top:-2px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-status-icon{color:rgba(255,255,255,.65);border-radius:50%;font-size:30px;height:40px;line-height:40px;text-align:center;width:40px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main{display:none;padding:0 10px 10px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-results-label{font-weight:700;margin-bottom:10px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers{margin:0;padding:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer{padding:0;margin:0 30px 0 0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer:only-child{list-style-type:none;margin-right:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main img{height:auto;max-width:200px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-attempt-answer-section{border-top:2px solid rgba(255,255,255,.5);margin-top:20px;padding-top:20px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-attempt-answer-section:first-child{border-top:none;margin-top:0;padding-top:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_choice ul.llms-quiz-attempt-answers,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_reorder ul.llms-quiz-attempt-answers{list-style-type:none;margin:0;padding:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_choice ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_reorder ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer{display:inline-block;list-style-type:none;margin:0;padding:5px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--removed{opacity:.5}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--removed .llms-question-title{font-style:italic;font-weight:normal}.single-llms_quiz .llms-return{margin-bottom:10px}.single-llms_quiz .llms-quiz-results:before,.single-llms_quiz .llms-quiz-results:after{content:" ";display:table}.single-llms_quiz .llms-quiz-results:after{clear:both}.single-llms_quiz .llms-quiz-results .llms-donut.passing{color:#83c373}.single-llms_quiz .llms-quiz-results .llms-donut.passing svg path{stroke:#83c373}.single-llms_quiz .llms-quiz-results .llms-donut.pending{color:#555}.single-llms_quiz .llms-quiz-results .llms-donut.pending svg path{stroke:#555}.single-llms_quiz .llms-quiz-results .llms-donut.failing{color:#e5554e}.single-llms_quiz .llms-quiz-results .llms-donut.failing svg path{stroke:#e5554e}.single-llms_quiz .llms-quiz-results .llms-quiz-results-aside,.single-llms_quiz .llms-quiz-results .llms-quiz-results-main,.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{margin-bottom:20px}@media all and (min-width: 600px){.single-llms_quiz .llms-quiz-results .llms-quiz-results-aside{float:right;width:220px}.single-llms_quiz .llms-quiz-results .llms-quiz-results-main,.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{float:left;width:calc(100% - 300px)}.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{clear:left}}.single-llms_quiz ul.llms-quiz-meta-info,.single-llms_quiz ul.llms-quiz-meta-info li{list-style-type:none;margin:0;padding:0}.single-llms_quiz ul.llms-quiz-meta-info{margin-bottom:10px}.single-llms_quiz .llms-quiz-buttons{margin-top:10px;text-align:right}.single-llms_quiz .llms-quiz-buttons form{display:inline-block}.llms-quiz-question-wrapper{min-height:140px;position:relative}.llms-quiz-question-wrapper .llms-quiz-loading{bottom:20px;right:0;position:absolute;left:0;text-align:center;z-index:1}.llms-quiz-ui{background:#fcfcfc;padding:20px;position:relative}.llms-quiz-ui .llms-quiz-header{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex;margin:0 0 30px}.llms-quiz-ui .llms-progress{background-color:#f1f2f1;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;height:8px;margin:0;overflow:hidden}.llms-quiz-ui .llms-progress .progress-bar-complete{-webkit-transition:width .3s ease-in;transition:width .3s ease-in;width:0}.llms-quiz-ui .llms-error{background:#e5554e;border-radius:4px;color:#fff;margin:10px 0;padding:10px}.llms-quiz-ui .llms-error:before,.llms-quiz-ui .llms-error:after{content:" ";display:table}.llms-quiz-ui .llms-error:after{clear:both}.llms-quiz-ui .llms-error a{color:rgba(255,255,255,.6);float:left;font-size:22px;line-height:1;text-decoration:none}.llms-quiz-ui .llms-quiz-counter{display:none;color:#6a6a6a;float:left;font-size:18px}.llms-quiz-ui .llms-quiz-counter .llms-sep{margin:0 5px}.llms-quiz-ui .llms-quiz-nav{margin-top:20px}.llms-quiz-ui .llms-quiz-nav button{margin:0 0 0 10px}.llms-question-wrapper .llms-question-text{font-size:30px;font-weight:400;margin-bottom:15px}.llms-question-wrapper ol.llms-question-choices{list-style-type:none;margin:0;padding:0}.llms-question-wrapper ol.llms-question-choices li.llms-choice{border-bottom:1px solid #e8e8e8;margin:0;padding:0;position:relative}.llms-question-wrapper ol.llms-question-choices li.llms-choice:last-child{border-bottom:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture{border-bottom:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture label{display:inline-block;padding:0}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-marker{bottom:10px;margin:0;position:absolute;left:10px}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-choice-image{margin:2px;padding:20px;-webkit-transition:background .4s ease;transition:background .4s ease}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-choice-image img{display:block;width:100%}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture input:checked~.llms-choice-image{background:#efefef}.llms-question-wrapper ol.llms-question-choices li.llms-choice input{display:none;right:0;pointer-events:none;position:absolute;top:0;visibility:hidden}.llms-question-wrapper ol.llms-question-choices li.llms-choice label{display:block;margin:0;padding:10px 20px;position:relative}.llms-question-wrapper ol.llms-question-choices li.llms-choice label.hovered .llms-marker:not(.type--lister) .iterator{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice label.hovered .llms-marker:not(.type--lister) .fa{display:inline}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker{background:#f0f0f0;display:inline-block;font-size:20px;height:40px;line-height:40px;margin-left:10px;text-align:center;-webkit-transition:all .2s ease;transition:all .2s ease;vertical-align:middle;width:40px}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker .fa{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--lister,.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--checkbox{border-radius:4px}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--radio{border-radius:50%}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker{background:#ef476f;color:#fff}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker .iterator{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker .fa{display:inline}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-choice-text{display:inline-block;font-size:18px;font-weight:400;line-height:1.6;margin-bottom:0;vertical-align:middle;width:calc(100% - 60px)}.llms-quiz-timer{background:#fff;border:1px solid #83c373;border-radius:4px;color:#83c373;float:left;font-size:18px;line-height:1;margin-right:20px;padding:8px 12px;position:relative;white-space:nowrap;z-index:1}.llms-quiz-timer.color-half{border-color:#ff922b;color:#ff922b}.llms-quiz-timer.color-empty{border-color:#e5554e;color:#e5554e}.llms-quiz-timer .llms-tiles{display:inline-block;margin-right:5px}.voucher-expand{display:none}@media all and (min-width: 600px){.llms-access-plans.cols-1 .llms-access-plan{width:100%}.llms-access-plans.cols-2 .llms-access-plan{width:50%}.llms-access-plans.cols-3 .llms-access-plan{width:33.3333333333%}.llms-access-plans.cols-4 .llms-access-plan{width:25%}.llms-access-plans.cols-5 .llms-access-plan{width:20%}}.llms-free-enroll-form{margin-bottom:0}.llms-access-plan{-webkit-box-sizing:border-box;box-sizing:border-box;float:right;text-align:center;width:100%}.llms-access-plan .llms-access-plan-footer,.llms-access-plan .llms-access-plan-content{background:#f1f1f1}.llms-access-plan.featured .llms-access-plan-featured{background:#4ba9ff}.llms-access-plan.featured .llms-access-plan-footer,.llms-access-plan.featured .llms-access-plan-content{border-right:3px solid #2295ff;border-left:3px solid #2295ff}.llms-access-plan.featured .llms-access-plan-footer{border-bottom-color:#2295ff}.llms-access-plan.on-sale .price-regular{text-decoration:line-through}.llms-access-plan .stamp{background:#2295ff;color:#fff;font-size:11px;font-style:normal;font-weight:300;padding:2px 3px;vertical-align:top}.llms-access-plan .llms-access-plan-restrictions ul{margin:0}.llms-access-plan-featured{color:#fff;font-size:14px;font-weight:400;margin:0 2px 0 2px}.llms-access-plan-content{margin:0 2px 0}.llms-access-plan-content .llms-access-plan-pricing{padding:10px 0 0}.llms-access-plan-title{background:#2295ff;color:#fff;margin-bottom:0;padding:10px}.llms-access-plan-pricing .llms-price-currency-symbol{font-size:14px;vertical-align:top}.llms-access-plan-price{font-size:18px;font-variant:small-caps;line-height:20px}.llms-access-plan-price .lifterlms-price{font-weight:700}.llms-access-plan-price.sale{padding:5px 0;border-top:1px solid #d0d0d0;border-bottom:1px solid #d0d0d0}.llms-access-plan-trial,.llms-access-plan-schedule,.llms-access-plan-sale-end,.llms-access-plan-expiration{font-size:15px;font-variant:small-caps;line-height:1.2}.llms-access-plan-description{font-size:16px;padding:10px 10px 0}.llms-access-plan-description ul{margin:0}.llms-access-plan-description ul li{border-bottom:1px solid #d0d0d0;list-style-type:none}.llms-access-plan-description ul li:last-child{border-bottom:none}.llms-access-plan-description div:last-child,.llms-access-plan-description img:last-child,.llms-access-plan-description p:last-child,.llms-access-plan-description ul:last-child,.llms-access-plan-description li:last-child{margin-bottom:0}.llms-access-plan-restrictions .stamp{vertical-align:baseline}.llms-access-plan-restrictions ul{margin:0}.llms-access-plan-restrictions ul li{font-size:12px;line-height:14px;list-style-type:none}.llms-access-plan-restrictions a{color:#f8954f}.llms-access-plan-restrictions a:hover{color:#f67d28}.llms-access-plan-footer{border-bottom:3px solid #f1f1f1;padding:10px;margin:0 2px 2px 2px}.llms-access-plan-footer .llms-access-plan-pricing{padding:0 0 10px}.webui-popover-content .llms-members-only-restrictions{text-align:center}.webui-popover-content .llms-members-only-restrictions ul,.webui-popover-content .llms-members-only-restrictions ol,.webui-popover-content .llms-members-only-restrictions li,.webui-popover-content .llms-members-only-restrictions p{margin:0;padding:0}.webui-popover-content .llms-members-only-restrictions ul,.webui-popover-content .llms-members-only-restrictions ol,.webui-popover-content .llms-members-only-restrictions li{list-style-type:none}.webui-popover-content .llms-members-only-restrictions li{padding:8px 0;border-top:1px solid #3b3b3b}.webui-popover-content .llms-members-only-restrictions li:first-child{border-top:none}.webui-popover-content .llms-members-only-restrictions li a{display:block}.llms-checkout-wrapper form.llms-login{border:3px solid #2295ff;display:none;margin-bottom:10px}.llms-checkout-wrapper .llms-form-heading{background:#2295ff;color:#fff;margin:0 0 5px;padding:10px}.llms-checkout{background:#fff;position:relative}@media all and (min-width: 800px){.llms-checkout-cols-2 .llms-checkout-col{float:right}.llms-checkout-cols-2 .llms-checkout-col.llms-col-1{margin-left:5px;width:calc(58% - 5px)}.llms-checkout-cols-2 .llms-checkout-col.llms-col-2{margin-right:5px;width:calc(42% - 5px)}.llms-checkout-cols-2 .llms-checkout-col.llms-col-2 button{width:100%}}.llms-checkout-section{border:3px solid #2295ff;margin-bottom:10px;position:relative}.llms-checkout-section-content{margin:10px}.llms-checkout-section-content.llms-form-fields{margin:0px}.llms-checkout-section-content .llms-label{font-weight:400;font-variant:small-caps;text-transform:lowercase}.llms-checkout-section-content .llms-order-summary{list-style-type:none;margin:0;padding:0}.llms-checkout-section-content .llms-order-summary li{list-style-type:none}.llms-checkout-section-content .llms-order-summary li.llms-pricing.on-sale .price-regular,.llms-checkout-section-content .llms-order-summary li.llms-pricing.has-coupon .price-regular{text-decoration:line-through}.llms-checkout-section-content .llms-coupon-wrapper{border-top:1px solid #dadada;margin-top:10px;padding-top:10px}.llms-checkout-section-content .llms-coupon-wrapper .llms-coupon-entry{display:none;margin-top:10px}.llms-form-field.llms-payment-gateway-option label+span.llms-description{display:inline-block;margin-right:5px}.llms-form-field.llms-payment-gateway-option .llms-description a{border:none;-webkit-box-shadow:none;box-shadow:none;text-decoration:none}.llms-form-field.llms-payment-gateway-option .llms-description img{display:inline;max-height:22px;vertical-align:middle}.llms-checkout-wrapper ul.llms-payment-gateways{margin:5px 0 0;padding:0}ul.llms-payment-gateways{list-style-type:none}ul.llms-payment-gateways li:last-child:after{border-bottom:1px solid #dadada;content:"";display:block;margin:10px}ul.llms-payment-gateways .llms-payment-gateway{margin-bottom:5px;list-style-type:none}ul.llms-payment-gateways .llms-payment-gateway:last-child{margin-bottom:none}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-payment-gateway-option label{font-weight:700}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-gateway-fields{display:block}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-gateway-fields .llms-notice{margin-right:10px;margin-left:10px}ul.llms-payment-gateways .llms-payment-gateway .llms-form-field{padding-bottom:0}ul.llms-payment-gateways .llms-gateway-description{margin-right:40px}ul.llms-payment-gateways .llms-gateway-fields{display:none;margin:5px 0 20px}ul.llms-payment-gateways .llms-payment-gateway-error{padding:0 10px}.llms-checkout-confirm{margin:0 10px}.llms-payment-method{margin:10px 10px 0}.llms-gateway-description p{font-size:85%;font-style:italic;margin-bottom:0}.llms-form-fields{-webkit-box-sizing:border-box;box-sizing:border-box}.llms-form-fields *{-webkit-box-sizing:border-box;box-sizing:border-box}.llms-form-fields.flush .llms-form-field{padding:0 0 10px}.llms-form-fields .wp-block-columns,.llms-form-fields .wp-block-column{margin-bottom:0}.llms-form-heading{padding:0 10px 10px}.llms-form-field{float:right;padding:0 10px 10px;position:relative;width:100%}.llms-form-field label:empty:after{content:" "}.llms-form-field.valid input[type=date],.llms-form-field.valid input[type=time],.llms-form-field.valid input[type=datetime-local],.llms-form-field.valid input[type=week],.llms-form-field.valid input[type=month],.llms-form-field.valid input[type=text],.llms-form-field.valid input[type=email],.llms-form-field.valid input[type=url],.llms-form-field.valid input[type=password],.llms-form-field.valid input[type=search],.llms-form-field.valid input[type=tel],.llms-form-field.valid input[type=number],.llms-form-field.valid textarea,.llms-form-field.valid select{background:rgba(131,195,115,.3);border-color:#83c373}.llms-form-field.error input[type=date],.llms-form-field.error input[type=time],.llms-form-field.error input[type=datetime-local],.llms-form-field.error input[type=week],.llms-form-field.error input[type=month],.llms-form-field.error input[type=text],.llms-form-field.error input[type=email],.llms-form-field.error input[type=url],.llms-form-field.error input[type=password],.llms-form-field.error input[type=search],.llms-form-field.error input[type=tel],.llms-form-field.error input[type=number],.llms-form-field.error textarea,.llms-form-field.error select,.llms-form-field.invalid input[type=date],.llms-form-field.invalid input[type=time],.llms-form-field.invalid input[type=datetime-local],.llms-form-field.invalid input[type=week],.llms-form-field.invalid input[type=month],.llms-form-field.invalid input[type=text],.llms-form-field.invalid input[type=email],.llms-form-field.invalid input[type=url],.llms-form-field.invalid input[type=password],.llms-form-field.invalid input[type=search],.llms-form-field.invalid input[type=tel],.llms-form-field.invalid input[type=number],.llms-form-field.invalid textarea,.llms-form-field.invalid select{background:rgba(229,85,78,.3);border-color:#e5554e}.llms-form-field.llms-visually-hidden-field{display:none}.llms-form-field.align-right{text-align:left}@media screen and (min-width: 600px){.llms-form-field.llms-cols-1{width:8.3333333333%}.llms-form-field.llms-cols-2{width:16.6666666667%}.llms-form-field.llms-cols-3{width:25%}.llms-form-field.llms-cols-4{width:33.3333333333%}.llms-form-field.llms-cols-5{width:41.6666666667%}.llms-form-field.llms-cols-6{width:50%}.llms-form-field.llms-cols-7{width:58.3333333333%}.llms-form-field.llms-cols-8{width:66.6666666667%}.llms-form-field.llms-cols-9{width:75%}.llms-form-field.llms-cols-10{width:83.3333333333%}.llms-form-field.llms-cols-11{width:91.6666666667%}.llms-form-field.llms-cols-12{width:100%}}.llms-form-field.type-hidden{padding:0}.llms-form-field.type-radio input,.llms-form-field.type-radio label,.llms-form-field.type-checkbox input,.llms-form-field.type-checkbox label{display:inline-block;width:auto}.llms-form-field.type-radio input,.llms-form-field.type-checkbox input{margin-left:5px}.llms-form-field.type-radio label+.llms-description,.llms-form-field.type-checkbox label+.llms-description{display:block}.llms-form-field.type-radio:not(.is-group) input[type=radio]{position:absolute;opacity:0;visibility:none}.llms-form-field.type-radio:not(.is-group) label:before{background:#fafafa;background-position:-24px 0;background-repeat:no-repeat;border-radius:50%;-webkit-box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.35) 0 0 0 1px;box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.35) 0 0 0 1px;content:"";cursor:pointer;display:inline-block;height:22px;margin-left:5px;position:relative;-webkit-transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);top:-3px;vertical-align:middle;width:22px;z-index:2}.llms-form-field.type-radio:not(.is-group) input[type=radio]:checked+label:before{-webkit-transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);background-position:100% 0;background-image:radial-gradient(ellipse at center, #2295ff 0%, #2295ff 40%, #fafafa 45%)}.llms-form-field .llms-input-group{margin-top:5px}.llms-form-field .llms-input-group .llms-form-field{padding:0 5px 5px 0}.llms-form-field.type-reset button:not(.auto),.llms-form-field.type-button button:not(.auto),.llms-form-field.type-submit button:not(.auto){width:100%}.llms-form-field .llms-description{font-size:14px;font-style:italic}.llms-form-field .llms-required{color:#e5554e;margin-right:4px}.llms-form-field input,.llms-form-field textarea,.llms-form-field select{width:100%;margin-bottom:5px}.llms-form-field .select2-container .select2-selection--single{height:auto;padding:4px 6px}.llms-form-field .select2-container--default .select2-selection--single .select2-selection__arrow{height:100%}.llms-password-strength-meter{border:1px solid #dadada;display:none;font-size:10px;margin-top:-10px;padding:1px;position:relative;text-align:center}.llms-password-strength-meter:before{bottom:0;content:"";right:0;position:absolute;top:0;-webkit-transition:width .4s ease;transition:width .4s ease}.llms-password-strength-meter.mismatch,.llms-password-strength-meter.too-short,.llms-password-strength-meter.very-weak{border-color:#e35b5b}.llms-password-strength-meter.mismatch:before,.llms-password-strength-meter.too-short:before,.llms-password-strength-meter.very-weak:before{background:rgba(227,91,91,.25);width:25%}.llms-password-strength-meter.too-short:before{width:0}.llms-password-strength-meter.weak{border-color:#f78b53}.llms-password-strength-meter.weak:before{background:rgba(247,139,83,.25);width:50%}.llms-password-strength-meter.medium{border-color:#ffc733}.llms-password-strength-meter.medium:before{background:rgba(255,199,51,.25);width:75%}.llms-password-strength-meter.strong{border-color:#83c373}.llms-password-strength-meter.strong:before{background:rgba(131,195,115,.25);width:100%}.llms-widget-syllabus--collapsible .llms-section .section-header{cursor:pointer}.llms-widget-syllabus--collapsible .llms-section.llms-section--opened .llms-collapse-caret .fa-caret-right{display:none}.llms-widget-syllabus--collapsible .llms-section.llms-section--closed .llms-collapse-caret .fa-caret-down{display:none}.llms-widget-syllabus--collapsible .llms-section.llms-section--closed .llms-lesson{display:none}.llms-widget-syllabus--collapsible .llms-syllabus-footer{text-align:right}.llms-student-dashboard .llms-sd-title{margin:25px 0}.llms-student-dashboard .llms-sd-items{list-style-type:none;margin:0;padding:0}.llms-student-dashboard .llms-sd-item{float:right;list-style-type:none;margin:0;padding:0}.llms-student-dashboard .llms-sd-item:last-child .llms-sep{display:none}.llms-student-dashboard .llms-sd-item .llms-sep{color:#333;margin:0 5px}.llms-student-dashboard .llms-sd-section{margin-bottom:25px}.llms-student-dashboard .llms-sd-section .llms-sd-section-footer{margin-top:10px}.llms-student-dashboard .orders-table{border:1px solid #f5f5f5;width:100%}.llms-student-dashboard .orders-table thead{display:none}.llms-student-dashboard .orders-table thead th,.llms-student-dashboard .orders-table thead td{font-weight:700}@media all and (min-width: 600px){.llms-student-dashboard .orders-table thead{display:table-header-group}}.llms-student-dashboard .orders-table tbody tr:nth-child(even) td,.llms-student-dashboard .orders-table tbody tr:nth-child(even) th{background:#f9f9f9}.llms-student-dashboard .orders-table tfoot th,.llms-student-dashboard .orders-table tfoot td{padding:10px;text-align:left}.llms-student-dashboard .orders-table tfoot th:last-child,.llms-student-dashboard .orders-table tfoot td:last-child{border-bottom-width:0}.llms-student-dashboard .orders-table th{font-weight:700}.llms-student-dashboard .orders-table th,.llms-student-dashboard .orders-table td{border-color:#efefef;border-style:solid;border-width:0;display:block;padding:8px 12px;text-align:center}.llms-student-dashboard .orders-table th .llms-button-primary,.llms-student-dashboard .orders-table td .llms-button-primary{display:inline-block}.llms-student-dashboard .orders-table th:last-child,.llms-student-dashboard .orders-table td:last-child{border-bottom-width:1px}.llms-student-dashboard .orders-table th:before,.llms-student-dashboard .orders-table td:before{content:attr(data-label)}@media all and (min-width: 600px){.llms-student-dashboard .orders-table th,.llms-student-dashboard .orders-table td{border-bottom-width:1px;display:table-cell;text-align:right}.llms-student-dashboard .orders-table th:first-child,.llms-student-dashboard .orders-table td:first-child{width:220px}.llms-student-dashboard .orders-table th:before,.llms-student-dashboard .orders-table td:before{display:none}}@media all and (min-width: 600px){.llms-student-dashboard .orders-table.transactions th:first-child{width:auto}}.llms-student-dashboard .llms-status{border-radius:3px;border-bottom:1px solid #fff;display:inline-block;font-size:80%;padding:3px 6px;vertical-align:middle}.llms-student-dashboard .llms-status.llms-size--large{font-size:105%;padding:6px 12px}.llms-student-dashboard .llms-status.llms-active,.llms-student-dashboard .llms-status.llms-completed,.llms-student-dashboard .llms-status.llms-pass,.llms-student-dashboard .llms-status.llms-txn-succeeded{color:#1f3818;background-color:#83c373}.llms-student-dashboard .llms-status.llms-fail,.llms-student-dashboard .llms-status.llms-failed,.llms-student-dashboard .llms-status.llms-expired,.llms-student-dashboard .llms-status.llms-cancelled,.llms-student-dashboard .llms-status.llms-txn-failed{color:#5a110d;background-color:#e5554e}.llms-student-dashboard .llms-status.llms-incomplete,.llms-student-dashboard .llms-status.llms-on-hold,.llms-student-dashboard .llms-status.llms-pending,.llms-student-dashboard .llms-status.llms-pending-cancel,.llms-student-dashboard .llms-status.llms-refunded,.llms-student-dashboard .llms-status.llms-txn-pending,.llms-student-dashboard .llms-status.llms-txn-refunded{color:#664200;background-color:orange}.llms-student-dashboard .llms-person-form-wrapper .llms-change-password{display:none}@media all and (min-width: 600px){.llms-student-dashboard .order-primary{float:right;width:68%}}@media all and (min-width: 600px){.llms-student-dashboard .order-secondary{float:right;width:32%}}.llms-student-dashboard .order-secondary form{margin-bottom:0}@media all and (min-width: 600px){.llms-student-dashboard .llms-view-order.llms-stack-cols .order-primary,.llms-student-dashboard .llms-view-order.llms-stack-cols .order-secondary{float:none;width:100%}}.llms-student-dashboard .llms-switch-payment-source .llms-notice,.llms-student-dashboard .llms-switch-payment-source .entry-content .llms-notice{margin-right:10px;margin-left:10px}.llms-student-dashboard .llms-switch-payment-source-main{border:none;display:none;margin:0}.llms-student-dashboard .llms-switch-payment-source-main ul.llms-payment-gateways{padding:10px 15px 0;margin:0}.llms-student-dashboard .llms-switch-payment-source-main .llms-payment-method,.llms-student-dashboard .llms-switch-payment-source-main ul.llms-order-summary{padding:0 25px 10px;margin:0;list-style-type:none}.llms-student-dashboard .llms-switch-payment-source-main .llms-payment-method li,.llms-student-dashboard .llms-switch-payment-source-main ul.llms-order-summary li{list-style-type:none}.llms-student-dashboard .llms-loop-list{margin:0 -10px}.llms-sd-grades .llms-table .llms-progress{display:block;margin:0}.llms-sd-grades .llms-table .llms-progress .llms-progress-bar{top:0;height:1.4em}.llms-sd-grades .llms-table .llms-progress .progress__indicator{font-size:1em;position:relative;left:.4em;top:.2em;z-index:1}.llms-table.llms-single-course-grades tbody tr:first-child td,.llms-table.llms-single-course-grades tbody tr:first-child th{background-color:#eaeaea}.llms-table.llms-single-course-grades th{font-weight:400}.llms-table.llms-single-course-grades td .llms-donut{display:inline-block;vertical-align:middle}.llms-table.llms-single-course-grades td .llms-status{margin-left:4px}.llms-table.llms-single-course-grades td .llms-donut+.llms-status{margin-right:4px}.llms-table.llms-single-course-grades th.llms-section_title{font-size:110%;font-weight:700}.llms-table.llms-single-course-grades td.llms-lesson_title{padding-right:36px;max-width:40%}.llms-table.llms-single-course-grades td.llms-associated_quiz .llms-donut{display:inline-block;margin-left:5px;vertical-align:middle}.llms-table.llms-single-course-grades td.llms-lesson_title a[href="#"]{pointer-events:none}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"]{color:inherit;position:relative}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"] .llms-tooltip{max-width:380px;width:380px}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"] .llms-tooltip.show{top:-54px}.llms-sd-widgets{display:-webkit-box;display:-ms-flexbox;display:flex}.llms-sd-widgets .llms-sd-widget{background:#f9f9f9;-webkit-box-flex:1;-ms-flex:1;flex:1;margin:10px 10px 20px;padding:0 0 20px}.llms-sd-widgets .llms-sd-widget:first-child{margin-right:0}.llms-sd-widgets .llms-sd-widget:last-child{margin-left:0}.llms-sd-widgets .llms-sd-widget .llms-sd-widget-title{background:#2295ff;color:#fff;font-size:18px;line-height:1;margin:0 0 20px;padding:10px}.llms-sd-widgets .llms-sd-widget .llms-sd-widget-empty{font-size:14px;font-style:italic;opacity:.5;text-align:center}.llms-sd-widgets .llms-sd-widget .llms-donut{margin:0 auto}.llms-sd-widgets .llms-sd-widget .llms-sd-date{opacity:.8;text-align:center;font-size:22px;line-height:1.1}.llms-sd-widgets .llms-sd-widget .llms-sd-date span{display:block}.llms-sd-widgets .llms-sd-widget .llms-sd-date span.day{font-size:52px}.llms-sd-widgets .llms-sd-widget .llms-sd-date span.diff{font-size:12px;font-style:italic;margin-top:8px;opacity:.75}.llms-sd-widgets .llms-sd-widget .llms-achievement{background:rgba(0,0,0,0);margin:0 auto;max-width:120px}.llms-sd-widgets .llms-sd-widget .llms-achievement .llms-achievement-title{display:none}.llms-sd-pagination{margin-top:24px}.llms-sd-pagination:before,.llms-sd-pagination:after{content:" ";display:table}.llms-sd-pagination:after{clear:both}.llms-sd-pagination .llms-button-secondary{display:inline-block}.llms-sd-pagination .llms-button-secondary.prev{float:right}.llms-sd-pagination .llms-button-secondary.next{float:left}.llms-sd-notification-center .llms-notification{z-index:1}.llms-table{border:1px solid #efefef;width:100%}.llms-table thead th,.llms-table thead td{font-weight:700}.llms-table tbody tr:nth-child(odd) td,.llms-table tbody tr:nth-child(odd) th{background:#f9f9f9}.llms-table tbody tr:last-child{border-bottom-width:0}.llms-table tfoot tr{background:#f9f9f9}.llms-table tfoot tr .llms-pagination .page-numbers{margin:0}.llms-table tfoot tr .llms-table-sort{text-align:left}.llms-table tfoot tr .llms-table-sort form,.llms-table tfoot tr .llms-table-sort select,.llms-table tfoot tr .llms-table-sort input,.llms-table tfoot tr .llms-table-sort button{margin:0}.llms-table th{font-weight:700}.llms-table th,.llms-table td{border-bottom:1px solid #efefef;padding:8px 12px}.llms-table th:first-child,.llms-table td:first-child{padding-right:12px}.llms-table th:last-child,.llms-table td:last-child{padding-left:12px}#page .llms-table tfoot label{display:inline}#page .llms-table tfoot select{height:auto}/*! * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) */@font-face{font-family:"FontAwesome";src:url("../fonts/fontawesome-webfont.eot?v=4.7.0");src:url("../fonts/fontawesome-webfont.eot?#iefix&v=4.7.0") format("embedded-opentype"),url("../fonts/fontawesome-webfont.woff2?v=4.7.0") format("woff2"),url("../fonts/fontawesome-webfont.woff?v=4.7.0") format("woff"),url("../fonts/fontawesome-webfont.ttf?v=4.7.0") format("truetype"),url("../fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular") format("svg");font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571429em;text-align:center}.fa-ul{padding-right:0;margin-right:2.14285714em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;right:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.fa-li.fa-lg{right:-1.85714286em}.fa-border{padding:.2em .25em .15em;border:solid .08em #eee;border-radius:.1em}.fa-pull-left{float:right}.fa-pull-right{float:left}.fa.fa-pull-left{margin-left:.3em}.fa.fa-pull-right{margin-right:.3em}.pull-right{float:left}.pull-left{float:right}.fa.pull-left{margin-left:.3em}.fa.pull-right{margin-right:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(-359deg);transform:rotate(-359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(-359deg);transform:rotate(-359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(-90deg);transform:rotate(-90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(-180deg);transform:rotate(-180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(-270deg);transform:rotate(-270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{-webkit-filter:none;filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;right:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:""}.fa-music:before{content:""}.fa-search:before{content:""}.fa-envelope-o:before{content:""}.fa-heart:before{content:""}.fa-star:before{content:""}.fa-star-o:before{content:""}.fa-user:before{content:""}.fa-film:before{content:""}.fa-th-large:before{content:""}.fa-th:before{content:""}.fa-th-list:before{content:""}.fa-check:before{content:""}.fa-remove:before,.fa-close:before,.fa-times:before{content:""}.fa-search-plus:before{content:""}.fa-search-minus:before{content:""}.fa-power-off:before{content:""}.fa-signal:before{content:""}.fa-gear:before,.fa-cog:before{content:""}.fa-trash-o:before{content:""}.fa-home:before{content:""}.fa-file-o:before{content:""}.fa-clock-o:before{content:""}.fa-road:before{content:""}.fa-download:before{content:""}.fa-arrow-circle-o-down:before{content:""}.fa-arrow-circle-o-up:before{content:""}.fa-inbox:before{content:""}.fa-play-circle-o:before{content:""}.fa-rotate-right:before,.fa-repeat:before{content:""}.fa-refresh:before{content:""}.fa-list-alt:before{content:""}.fa-lock:before{content:""}.fa-flag:before{content:""}.fa-headphones:before{content:""}.fa-volume-off:before{content:""}.fa-volume-down:before{content:""}.fa-volume-up:before{content:""}.fa-qrcode:before{content:""}.fa-barcode:before{content:""}.fa-tag:before{content:""}.fa-tags:before{content:""}.fa-book:before{content:""}.fa-bookmark:before{content:""}.fa-print:before{content:""}.fa-camera:before{content:""}.fa-font:before{content:""}.fa-bold:before{content:""}.fa-italic:before{content:""}.fa-text-height:before{content:""}.fa-text-width:before{content:""}.fa-align-left:before{content:""}.fa-align-center:before{content:""}.fa-align-right:before{content:""}.fa-align-justify:before{content:""}.fa-list:before{content:""}.fa-dedent:before,.fa-outdent:before{content:""}.fa-indent:before{content:""}.fa-video-camera:before{content:""}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:""}.fa-pencil:before{content:""}.fa-map-marker:before{content:""}.fa-adjust:before{content:""}.fa-tint:before{content:""}.fa-edit:before,.fa-pencil-square-o:before{content:""}.fa-share-square-o:before{content:""}.fa-check-square-o:before{content:""}.fa-arrows:before{content:""}.fa-step-backward:before{content:""}.fa-fast-backward:before{content:""}.fa-backward:before{content:""}.fa-play:before{content:""}.fa-pause:before{content:""}.fa-stop:before{content:""}.fa-forward:before{content:""}.fa-fast-forward:before{content:""}.fa-step-forward:before{content:""}.fa-eject:before{content:""}.fa-chevron-left:before{content:""}.fa-chevron-right:before{content:""}.fa-plus-circle:before{content:""}.fa-minus-circle:before{content:""}.fa-times-circle:before{content:""}.fa-check-circle:before{content:""}.fa-question-circle:before{content:""}.fa-info-circle:before{content:""}.fa-crosshairs:before{content:""}.fa-times-circle-o:before{content:""}.fa-check-circle-o:before{content:""}.fa-ban:before{content:""}.fa-arrow-left:before{content:""}.fa-arrow-right:before{content:""}.fa-arrow-up:before{content:""}.fa-arrow-down:before{content:""}.fa-mail-forward:before,.fa-share:before{content:""}.fa-expand:before{content:""}.fa-compress:before{content:""}.fa-plus:before{content:""}.fa-minus:before{content:""}.fa-asterisk:before{content:""}.fa-exclamation-circle:before{content:""}.fa-gift:before{content:""}.fa-leaf:before{content:""}.fa-fire:before{content:""}.fa-eye:before{content:""}.fa-eye-slash:before{content:""}.fa-warning:before,.fa-exclamation-triangle:before{content:""}.fa-plane:before{content:""}.fa-calendar:before{content:""}.fa-random:before{content:""}.fa-comment:before{content:""}.fa-magnet:before{content:""}.fa-chevron-up:before{content:""}.fa-chevron-down:before{content:""}.fa-retweet:before{content:""}.fa-shopping-cart:before{content:""}.fa-folder:before{content:""}.fa-folder-open:before{content:""}.fa-arrows-v:before{content:""}.fa-arrows-h:before{content:""}.fa-bar-chart-o:before,.fa-bar-chart:before{content:""}.fa-twitter-square:before{content:""}.fa-facebook-square:before{content:""}.fa-camera-retro:before{content:""}.fa-key:before{content:""}.fa-gears:before,.fa-cogs:before{content:""}.fa-comments:before{content:""}.fa-thumbs-o-up:before{content:""}.fa-thumbs-o-down:before{content:""}.fa-star-half:before{content:""}.fa-heart-o:before{content:""}.fa-sign-out:before{content:""}.fa-linkedin-square:before{content:""}.fa-thumb-tack:before{content:""}.fa-external-link:before{content:""}.fa-sign-in:before{content:""}.fa-trophy:before{content:""}.fa-github-square:before{content:""}.fa-upload:before{content:""}.fa-lemon-o:before{content:""}.fa-phone:before{content:""}.fa-square-o:before{content:""}.fa-bookmark-o:before{content:""}.fa-phone-square:before{content:""}.fa-twitter:before{content:""}.fa-facebook-f:before,.fa-facebook:before{content:""}.fa-github:before{content:""}.fa-unlock:before{content:""}.fa-credit-card:before{content:""}.fa-feed:before,.fa-rss:before{content:""}.fa-hdd-o:before{content:""}.fa-bullhorn:before{content:""}.fa-bell:before{content:""}.fa-certificate:before{content:""}.fa-hand-o-right:before{content:""}.fa-hand-o-left:before{content:""}.fa-hand-o-up:before{content:""}.fa-hand-o-down:before{content:""}.fa-arrow-circle-left:before{content:""}.fa-arrow-circle-right:before{content:""}.fa-arrow-circle-up:before{content:""}.fa-arrow-circle-down:before{content:""}.fa-globe:before{content:""}.fa-wrench:before{content:""}.fa-tasks:before{content:""}.fa-filter:before{content:""}.fa-briefcase:before{content:""}.fa-arrows-alt:before{content:""}.fa-group:before,.fa-users:before{content:""}.fa-chain:before,.fa-link:before{content:""}.fa-cloud:before{content:""}.fa-flask:before{content:""}.fa-cut:before,.fa-scissors:before{content:""}.fa-copy:before,.fa-files-o:before{content:""}.fa-paperclip:before{content:""}.fa-save:before,.fa-floppy-o:before{content:""}.fa-square:before{content:""}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:""}.fa-list-ul:before{content:""}.fa-list-ol:before{content:""}.fa-strikethrough:before{content:""}.fa-underline:before{content:""}.fa-table:before{content:""}.fa-magic:before{content:""}.fa-truck:before{content:""}.fa-pinterest:before{content:""}.fa-pinterest-square:before{content:""}.fa-google-plus-square:before{content:""}.fa-google-plus:before{content:""}.fa-money:before{content:""}.fa-caret-down:before{content:""}.fa-caret-up:before{content:""}.fa-caret-left:before{content:""}.fa-caret-right:before{content:""}.fa-columns:before{content:""}.fa-unsorted:before,.fa-sort:before{content:""}.fa-sort-down:before,.fa-sort-desc:before{content:""}.fa-sort-up:before,.fa-sort-asc:before{content:""}.fa-envelope:before{content:""}.fa-linkedin:before{content:""}.fa-rotate-left:before,.fa-undo:before{content:""}.fa-legal:before,.fa-gavel:before{content:""}.fa-dashboard:before,.fa-tachometer:before{content:""}.fa-comment-o:before{content:""}.fa-comments-o:before{content:""}.fa-flash:before,.fa-bolt:before{content:""}.fa-sitemap:before{content:""}.fa-umbrella:before{content:""}.fa-paste:before,.fa-clipboard:before{content:""}.fa-lightbulb-o:before{content:""}.fa-exchange:before{content:""}.fa-cloud-download:before{content:""}.fa-cloud-upload:before{content:""}.fa-user-md:before{content:""}.fa-stethoscope:before{content:""}.fa-suitcase:before{content:""}.fa-bell-o:before{content:""}.fa-coffee:before{content:""}.fa-cutlery:before{content:""}.fa-file-text-o:before{content:""}.fa-building-o:before{content:""}.fa-hospital-o:before{content:""}.fa-ambulance:before{content:""}.fa-medkit:before{content:""}.fa-fighter-jet:before{content:""}.fa-beer:before{content:""}.fa-h-square:before{content:""}.fa-plus-square:before{content:""}.fa-angle-double-left:before{content:""}.fa-angle-double-right:before{content:""}.fa-angle-double-up:before{content:""}.fa-angle-double-down:before{content:""}.fa-angle-left:before{content:""}.fa-angle-right:before{content:""}.fa-angle-up:before{content:""}.fa-angle-down:before{content:""}.fa-desktop:before{content:""}.fa-laptop:before{content:""}.fa-tablet:before{content:""}.fa-mobile-phone:before,.fa-mobile:before{content:""}.fa-circle-o:before{content:""}.fa-quote-left:before{content:""}.fa-quote-right:before{content:""}.fa-spinner:before{content:""}.fa-circle:before{content:""}.fa-mail-reply:before,.fa-reply:before{content:""}.fa-github-alt:before{content:""}.fa-folder-o:before{content:""}.fa-folder-open-o:before{content:""}.fa-smile-o:before{content:""}.fa-frown-o:before{content:""}.fa-meh-o:before{content:""}.fa-gamepad:before{content:""}.fa-keyboard-o:before{content:""}.fa-flag-o:before{content:""}.fa-flag-checkered:before{content:""}.fa-terminal:before{content:""}.fa-code:before{content:""}.fa-mail-reply-all:before,.fa-reply-all:before{content:""}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:""}.fa-location-arrow:before{content:""}.fa-crop:before{content:""}.fa-code-fork:before{content:""}.fa-unlink:before,.fa-chain-broken:before{content:""}.fa-question:before{content:""}.fa-info:before{content:""}.fa-exclamation:before{content:""}.fa-superscript:before{content:""}.fa-subscript:before{content:""}.fa-eraser:before{content:""}.fa-puzzle-piece:before{content:""}.fa-microphone:before{content:""}.fa-microphone-slash:before{content:""}.fa-shield:before{content:""}.fa-calendar-o:before{content:""}.fa-fire-extinguisher:before{content:""}.fa-rocket:before{content:""}.fa-maxcdn:before{content:""}.fa-chevron-circle-left:before{content:""}.fa-chevron-circle-right:before{content:""}.fa-chevron-circle-up:before{content:""}.fa-chevron-circle-down:before{content:""}.fa-html5:before{content:""}.fa-css3:before{content:""}.fa-anchor:before{content:""}.fa-unlock-alt:before{content:""}.fa-bullseye:before{content:""}.fa-ellipsis-h:before{content:""}.fa-ellipsis-v:before{content:""}.fa-rss-square:before{content:""}.fa-play-circle:before{content:""}.fa-ticket:before{content:""}.fa-minus-square:before{content:""}.fa-minus-square-o:before{content:""}.fa-level-up:before{content:""}.fa-level-down:before{content:""}.fa-check-square:before{content:""}.fa-pencil-square:before{content:""}.fa-external-link-square:before{content:""}.fa-share-square:before{content:""}.fa-compass:before{content:""}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:""}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:""}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:""}.fa-euro:before,.fa-eur:before{content:""}.fa-gbp:before{content:""}.fa-dollar:before,.fa-usd:before{content:""}.fa-rupee:before,.fa-inr:before{content:""}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:""}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:""}.fa-won:before,.fa-krw:before{content:""}.fa-bitcoin:before,.fa-btc:before{content:""}.fa-file:before{content:""}.fa-file-text:before{content:""}.fa-sort-alpha-asc:before{content:""}.fa-sort-alpha-desc:before{content:""}.fa-sort-amount-asc:before{content:""}.fa-sort-amount-desc:before{content:""}.fa-sort-numeric-asc:before{content:""}.fa-sort-numeric-desc:before{content:""}.fa-thumbs-up:before{content:""}.fa-thumbs-down:before{content:""}.fa-youtube-square:before{content:""}.fa-youtube:before{content:""}.fa-xing:before{content:""}.fa-xing-square:before{content:""}.fa-youtube-play:before{content:""}.fa-dropbox:before{content:""}.fa-stack-overflow:before{content:""}.fa-instagram:before{content:""}.fa-flickr:before{content:""}.fa-adn:before{content:""}.fa-bitbucket:before{content:""}.fa-bitbucket-square:before{content:""}.fa-tumblr:before{content:""}.fa-tumblr-square:before{content:""}.fa-long-arrow-down:before{content:""}.fa-long-arrow-up:before{content:""}.fa-long-arrow-left:before{content:""}.fa-long-arrow-right:before{content:""}.fa-apple:before{content:""}.fa-windows:before{content:""}.fa-android:before{content:""}.fa-linux:before{content:""}.fa-dribbble:before{content:""}.fa-skype:before{content:""}.fa-foursquare:before{content:""}.fa-trello:before{content:""}.fa-female:before{content:""}.fa-male:before{content:""}.fa-gittip:before,.fa-gratipay:before{content:""}.fa-sun-o:before{content:""}.fa-moon-o:before{content:""}.fa-archive:before{content:""}.fa-bug:before{content:""}.fa-vk:before{content:""}.fa-weibo:before{content:""}.fa-renren:before{content:""}.fa-pagelines:before{content:""}.fa-stack-exchange:before{content:""}.fa-arrow-circle-o-right:before{content:""}.fa-arrow-circle-o-left:before{content:""}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:""}.fa-dot-circle-o:before{content:""}.fa-wheelchair:before{content:""}.fa-vimeo-square:before{content:""}.fa-turkish-lira:before,.fa-try:before{content:""}.fa-plus-square-o:before{content:""}.fa-space-shuttle:before{content:""}.fa-slack:before{content:""}.fa-envelope-square:before{content:""}.fa-wordpress:before{content:""}.fa-openid:before{content:""}.fa-institution:before,.fa-bank:before,.fa-university:before{content:""}.fa-mortar-board:before,.fa-graduation-cap:before{content:""}.fa-yahoo:before{content:""}.fa-google:before{content:""}.fa-reddit:before{content:""}.fa-reddit-square:before{content:""}.fa-stumbleupon-circle:before{content:""}.fa-stumbleupon:before{content:""}.fa-delicious:before{content:""}.fa-digg:before{content:""}.fa-pied-piper-pp:before{content:""}.fa-pied-piper-alt:before{content:""}.fa-drupal:before{content:""}.fa-joomla:before{content:""}.fa-language:before{content:""}.fa-fax:before{content:""}.fa-building:before{content:""}.fa-child:before{content:""}.fa-paw:before{content:""}.fa-spoon:before{content:""}.fa-cube:before{content:""}.fa-cubes:before{content:""}.fa-behance:before{content:""}.fa-behance-square:before{content:""}.fa-steam:before{content:""}.fa-steam-square:before{content:""}.fa-recycle:before{content:""}.fa-automobile:before,.fa-car:before{content:""}.fa-cab:before,.fa-taxi:before{content:""}.fa-tree:before{content:""}.fa-spotify:before{content:""}.fa-deviantart:before{content:""}.fa-soundcloud:before{content:""}.fa-database:before{content:""}.fa-file-pdf-o:before{content:""}.fa-file-word-o:before{content:""}.fa-file-excel-o:before{content:""}.fa-file-powerpoint-o:before{content:""}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:""}.fa-file-zip-o:before,.fa-file-archive-o:before{content:""}.fa-file-sound-o:before,.fa-file-audio-o:before{content:""}.fa-file-movie-o:before,.fa-file-video-o:before{content:""}.fa-file-code-o:before{content:""}.fa-vine:before{content:""}.fa-codepen:before{content:""}.fa-jsfiddle:before{content:""}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:""}.fa-circle-o-notch:before{content:""}.fa-ra:before,.fa-resistance:before,.fa-rebel:before{content:""}.fa-ge:before,.fa-empire:before{content:""}.fa-git-square:before{content:""}.fa-git:before{content:""}.fa-y-combinator-square:before,.fa-yc-square:before,.fa-hacker-news:before{content:""}.fa-tencent-weibo:before{content:""}.fa-qq:before{content:""}.fa-wechat:before,.fa-weixin:before{content:""}.fa-send:before,.fa-paper-plane:before{content:""}.fa-send-o:before,.fa-paper-plane-o:before{content:""}.fa-history:before{content:""}.fa-circle-thin:before{content:""}.fa-header:before{content:""}.fa-paragraph:before{content:""}.fa-sliders:before{content:""}.fa-share-alt:before{content:""}.fa-share-alt-square:before{content:""}.fa-bomb:before{content:""}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:""}.fa-tty:before{content:""}.fa-binoculars:before{content:""}.fa-plug:before{content:""}.fa-slideshare:before{content:""}.fa-twitch:before{content:""}.fa-yelp:before{content:""}.fa-newspaper-o:before{content:""}.fa-wifi:before{content:""}.fa-calculator:before{content:""}.fa-paypal:before{content:""}.fa-google-wallet:before{content:""}.fa-cc-visa:before{content:""}.fa-cc-mastercard:before{content:""}.fa-cc-discover:before{content:""}.fa-cc-amex:before{content:""}.fa-cc-paypal:before{content:""}.fa-cc-stripe:before{content:""}.fa-bell-slash:before{content:""}.fa-bell-slash-o:before{content:""}.fa-trash:before{content:""}.fa-copyright:before{content:""}.fa-at:before{content:""}.fa-eyedropper:before{content:""}.fa-paint-brush:before{content:""}.fa-birthday-cake:before{content:""}.fa-area-chart:before{content:""}.fa-pie-chart:before{content:""}.fa-line-chart:before{content:""}.fa-lastfm:before{content:""}.fa-lastfm-square:before{content:""}.fa-toggle-off:before{content:""}.fa-toggle-on:before{content:""}.fa-bicycle:before{content:""}.fa-bus:before{content:""}.fa-ioxhost:before{content:""}.fa-angellist:before{content:""}.fa-cc:before{content:""}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:""}.fa-meanpath:before{content:""}.fa-buysellads:before{content:""}.fa-connectdevelop:before{content:""}.fa-dashcube:before{content:""}.fa-forumbee:before{content:""}.fa-leanpub:before{content:""}.fa-sellsy:before{content:""}.fa-shirtsinbulk:before{content:""}.fa-simplybuilt:before{content:""}.fa-skyatlas:before{content:""}.fa-cart-plus:before{content:""}.fa-cart-arrow-down:before{content:""}.fa-diamond:before{content:""}.fa-ship:before{content:""}.fa-user-secret:before{content:""}.fa-motorcycle:before{content:""}.fa-street-view:before{content:""}.fa-heartbeat:before{content:""}.fa-venus:before{content:""}.fa-mars:before{content:""}.fa-mercury:before{content:""}.fa-intersex:before,.fa-transgender:before{content:""}.fa-transgender-alt:before{content:""}.fa-venus-double:before{content:""}.fa-mars-double:before{content:""}.fa-venus-mars:before{content:""}.fa-mars-stroke:before{content:""}.fa-mars-stroke-v:before{content:""}.fa-mars-stroke-h:before{content:""}.fa-neuter:before{content:""}.fa-genderless:before{content:""}.fa-facebook-official:before{content:""}.fa-pinterest-p:before{content:""}.fa-whatsapp:before{content:""}.fa-server:before{content:""}.fa-user-plus:before{content:""}.fa-user-times:before{content:""}.fa-hotel:before,.fa-bed:before{content:""}.fa-viacoin:before{content:""}.fa-train:before{content:""}.fa-subway:before{content:""}.fa-medium:before{content:""}.fa-yc:before,.fa-y-combinator:before{content:""}.fa-optin-monster:before{content:""}.fa-opencart:before{content:""}.fa-expeditedssl:before{content:""}.fa-battery-4:before,.fa-battery:before,.fa-battery-full:before{content:""}.fa-battery-3:before,.fa-battery-three-quarters:before{content:""}.fa-battery-2:before,.fa-battery-half:before{content:""}.fa-battery-1:before,.fa-battery-quarter:before{content:""}.fa-battery-0:before,.fa-battery-empty:before{content:""}.fa-mouse-pointer:before{content:""}.fa-i-cursor:before{content:""}.fa-object-group:before{content:""}.fa-object-ungroup:before{content:""}.fa-sticky-note:before{content:""}.fa-sticky-note-o:before{content:""}.fa-cc-jcb:before{content:""}.fa-cc-diners-club:before{content:""}.fa-clone:before{content:""}.fa-balance-scale:before{content:""}.fa-hourglass-o:before{content:""}.fa-hourglass-1:before,.fa-hourglass-start:before{content:""}.fa-hourglass-2:before,.fa-hourglass-half:before{content:""}.fa-hourglass-3:before,.fa-hourglass-end:before{content:""}.fa-hourglass:before{content:""}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:""}.fa-hand-stop-o:before,.fa-hand-paper-o:before{content:""}.fa-hand-scissors-o:before{content:""}.fa-hand-lizard-o:before{content:""}.fa-hand-spock-o:before{content:""}.fa-hand-pointer-o:before{content:""}.fa-hand-peace-o:before{content:""}.fa-trademark:before{content:""}.fa-registered:before{content:""}.fa-creative-commons:before{content:""}.fa-gg:before{content:""}.fa-gg-circle:before{content:""}.fa-tripadvisor:before{content:""}.fa-odnoklassniki:before{content:""}.fa-odnoklassniki-square:before{content:""}.fa-get-pocket:before{content:""}.fa-wikipedia-w:before{content:""}.fa-safari:before{content:""}.fa-chrome:before{content:""}.fa-firefox:before{content:""}.fa-opera:before{content:""}.fa-internet-explorer:before{content:""}.fa-tv:before,.fa-television:before{content:""}.fa-contao:before{content:""}.fa-500px:before{content:""}.fa-amazon:before{content:""}.fa-calendar-plus-o:before{content:""}.fa-calendar-minus-o:before{content:""}.fa-calendar-times-o:before{content:""}.fa-calendar-check-o:before{content:""}.fa-industry:before{content:""}.fa-map-pin:before{content:""}.fa-map-signs:before{content:""}.fa-map-o:before{content:""}.fa-map:before{content:""}.fa-commenting:before{content:""}.fa-commenting-o:before{content:""}.fa-houzz:before{content:""}.fa-vimeo:before{content:""}.fa-black-tie:before{content:""}.fa-fonticons:before{content:""}.fa-reddit-alien:before{content:""}.fa-edge:before{content:""}.fa-credit-card-alt:before{content:""}.fa-codiepie:before{content:""}.fa-modx:before{content:""}.fa-fort-awesome:before{content:""}.fa-usb:before{content:""}.fa-product-hunt:before{content:""}.fa-mixcloud:before{content:""}.fa-scribd:before{content:""}.fa-pause-circle:before{content:""}.fa-pause-circle-o:before{content:""}.fa-stop-circle:before{content:""}.fa-stop-circle-o:before{content:""}.fa-shopping-bag:before{content:""}.fa-shopping-basket:before{content:""}.fa-hashtag:before{content:""}.fa-bluetooth:before{content:""}.fa-bluetooth-b:before{content:""}.fa-percent:before{content:""}.fa-gitlab:before{content:""}.fa-wpbeginner:before{content:""}.fa-wpforms:before{content:""}.fa-envira:before{content:""}.fa-universal-access:before{content:""}.fa-wheelchair-alt:before{content:""}.fa-question-circle-o:before{content:""}.fa-blind:before{content:""}.fa-audio-description:before{content:""}.fa-volume-control-phone:before{content:""}.fa-braille:before{content:""}.fa-assistive-listening-systems:before{content:""}.fa-asl-interpreting:before,.fa-american-sign-language-interpreting:before{content:""}.fa-deafness:before,.fa-hard-of-hearing:before,.fa-deaf:before{content:""}.fa-glide:before{content:""}.fa-glide-g:before{content:""}.fa-signing:before,.fa-sign-language:before{content:""}.fa-low-vision:before{content:""}.fa-viadeo:before{content:""}.fa-viadeo-square:before{content:""}.fa-snapchat:before{content:""}.fa-snapchat-ghost:before{content:""}.fa-snapchat-square:before{content:""}.fa-pied-piper:before{content:""}.fa-first-order:before{content:""}.fa-yoast:before{content:""}.fa-themeisle:before{content:""}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:""}.fa-fa:before,.fa-font-awesome:before{content:""}.fa-handshake-o:before{content:""}.fa-envelope-open:before{content:""}.fa-envelope-open-o:before{content:""}.fa-linode:before{content:""}.fa-address-book:before{content:""}.fa-address-book-o:before{content:""}.fa-vcard:before,.fa-address-card:before{content:""}.fa-vcard-o:before,.fa-address-card-o:before{content:""}.fa-user-circle:before{content:""}.fa-user-circle-o:before{content:""}.fa-user-o:before{content:""}.fa-id-badge:before{content:""}.fa-drivers-license:before,.fa-id-card:before{content:""}.fa-drivers-license-o:before,.fa-id-card-o:before{content:""}.fa-quora:before{content:""}.fa-free-code-camp:before{content:""}.fa-telegram:before{content:""}.fa-thermometer-4:before,.fa-thermometer:before,.fa-thermometer-full:before{content:""}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:""}.fa-thermometer-2:before,.fa-thermometer-half:before{content:""}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:""}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:""}.fa-shower:before{content:""}.fa-bathtub:before,.fa-s15:before,.fa-bath:before{content:""}.fa-podcast:before{content:""}.fa-window-maximize:before{content:""}.fa-window-minimize:before{content:""}.fa-window-restore:before{content:""}.fa-times-rectangle:before,.fa-window-close:before{content:""}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:""}.fa-bandcamp:before{content:""}.fa-grav:before{content:""}.fa-etsy:before{content:""}.fa-imdb:before{content:""}.fa-ravelry:before{content:""}.fa-eercast:before{content:""}.fa-microchip:before{content:""}.fa-snowflake-o:before{content:""}.fa-superpowers:before{content:""}.fa-wpexplorer:before{content:""}.fa-meetup:before{content:""}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto} diff --git a/assets/css/lifterlms.css b/assets/css/lifterlms.css index a1aa861f1f..ad2ca573ee 100644 --- a/assets/css/lifterlms.css +++ b/assets/css/lifterlms.css @@ -1196,6 +1196,29 @@ svg .llms-animated-circle { display: inline-block; } +.llms-favorite-wrapper { + cursor: pointer; +} +.llms-favorite-wrapper .fa-heart { + color: #EF476F; +} + +.llms-has-favorite .llms-parent-course-link { + display: inline-block; + margin-bottom: 20px; +} +.llms-has-favorite .llms-parent-course-link + .llms-favorite-wrapper { + float: right; + margin: 0; +} + +.llms-syllabus-wrapper .llms-has-favorite { + text-align: left; +} +.llms-syllabus-wrapper .llms-has-favorite .llms-favorite-wrapper { + display: inline-block; +} + .llms-loop-list { list-style: none; margin: 0 -10px; diff --git a/assets/css/lifterlms.min.css b/assets/css/lifterlms.min.css index 4386a13e6f..8d2c8cde2a 100644 --- a/assets/css/lifterlms.min.css +++ b/assets/css/lifterlms.min.css @@ -1,4 +1,4 @@ -.llms-pagination ul:before,.llms-pagination ul:after,.llms-student-dashboard .llms-sd-items:before,.llms-form-fields:before,.llms-checkout-cols-2:before,.llms-access-plans:before,.llms-course-navigation:before,.llms-loop-list:before,.llms-cols:before,.llms-student-dashboard .llms-sd-items:after,.llms-form-fields:after,.llms-checkout-cols-2:after,.llms-access-plans:after,.llms-course-navigation:after,.llms-loop-list:after,.llms-cols:after{content:" ";display:table}.llms-pagination ul:after,.llms-student-dashboard .llms-sd-items:after,.llms-form-fields:after,.llms-checkout-cols-2:after,.llms-access-plans:after,.llms-course-navigation:after,.llms-loop-list:after,.llms-cols:after{clear:both}.llms-cols .llms-col{width:100%}@media all and (min-width: 600px){.llms-cols [class*=llms-col-]{float:left}}.llms-flex-cols{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-flow:row wrap;flex-flow:row wrap}.llms-flex-cols [class*=llms-col]{-webkit-box-flex:0;-ms-flex:0 1 auto;flex:0 1 auto;width:100%}@media all and (min-width: 600px){.llms-cols .llms-col-1,.llms-flex-cols .llms-col-1{width:100%}.llms-cols .llms-col-2,.llms-flex-cols .llms-col-2{width:50%}.llms-cols .llms-col-3,.llms-flex-cols .llms-col-3{width:33.3333333333%}.llms-cols .llms-col-4,.llms-flex-cols .llms-col-4{width:25%}.llms-cols .llms-col-5,.llms-flex-cols .llms-col-5{width:20%}.llms-cols .llms-col-6,.llms-flex-cols .llms-col-6{width:16.6666666667%}.llms-cols .llms-col-7,.llms-flex-cols .llms-col-7{width:14.2857142857%}.llms-cols .llms-col-8,.llms-flex-cols .llms-col-8{width:12.5%}.llms-cols .llms-col-9,.llms-flex-cols .llms-col-9{width:11.1111111111%}.llms-cols .llms-col-10,.llms-flex-cols .llms-col-10{width:10%}.llms-cols .llms-col-11,.llms-flex-cols .llms-col-11{width:9.0909090909%}.llms-cols .llms-col-12,.llms-flex-cols .llms-col-12{width:8.3333333333%}}.llms-button-action,.llms-button-danger,.llms-button-primary,.llms-button-secondary{border:none;border-radius:8px;color:#fefefe;cursor:pointer;font-size:16px;font-weight:700;text-decoration:none;text-shadow:none;line-height:1;margin:0;max-width:100%;padding:12px 24px;position:relative;-webkit-transition:all .5s ease;transition:all .5s ease}.llms-button-action:disabled,.llms-button-danger:disabled,.llms-button-primary:disabled,.llms-button-secondary:disabled{opacity:.5}.llms-button-action:hover,.llms-button-action:active,.llms-button-danger:hover,.llms-button-danger:active,.llms-button-primary:hover,.llms-button-primary:active,.llms-button-secondary:hover,.llms-button-secondary:active{color:#fefefe}.llms-button-action:focus,.llms-button-danger:focus,.llms-button-primary:focus,.llms-button-secondary:focus{color:#fefefe}.llms-button-action.auto,.llms-button-danger.auto,.llms-button-primary.auto,.llms-button-secondary.auto{width:auto}.llms-button-action.full,.llms-button-danger.full,.llms-button-primary.full,.llms-button-secondary.full{display:block;text-align:center;width:100%}.llms-button-action.square,.llms-button-danger.square,.llms-button-primary.square,.llms-button-secondary.square{padding:12px}.llms-button-action.small,.llms-button-danger.small,.llms-button-primary.small,.llms-button-secondary.small{font-size:13px;padding:8px 14px}.llms-button-action.small.square,.llms-button-danger.small.square,.llms-button-primary.small.square,.llms-button-secondary.small.square{padding:8px}.llms-button-action.large,.llms-button-danger.large,.llms-button-primary.large,.llms-button-secondary.large{font-size:18px;line-height:1.2;padding:16px 32px}.llms-button-action.large.square,.llms-button-danger.large.square,.llms-button-primary.large.square,.llms-button-secondary.large.square{padding:16px}.llms-button-action.large .fa,.llms-button-danger.large .fa,.llms-button-primary.large .fa,.llms-button-secondary.large .fa{left:-7px;position:relative}.llms-button-primary{background:#2295ff}.llms-button-primary:hover,.llms-button-primary.clicked{background:#0077e4}.llms-button-primary:focus,.llms-button-primary:active{background:#4ba9ff}.llms-button-secondary{background:#e1e1e1;color:#414141}.llms-button-secondary:hover{color:#414141;background:#cdcdcd}.llms-button-secondary:focus,.llms-button-secondary:active{color:#414141;background:#ebebeb}.llms-button-action{background:#f8954f}.llms-button-action:hover,.llms-button-action.clicked{background:#f67d28}.llms-button-action:focus,.llms-button-action:active{background:#faad76}.llms-button-danger{background:#e5554e}.llms-button-danger:hover{background:#e0332a}.llms-button-danger:focus,.llms-button-danger:active{background:#e86660}.llms-button-outline{background:rgba(0,0,0,0);border:3px solid #1d2327;border-radius:8px;color:#1d2327;cursor:pointer;font-size:16px;font-weight:700;text-decoration:none;text-shadow:none;line-height:1;margin:0;max-width:100%;padding:12px 24px;position:relative;-webkit-transition:all .5s ease;transition:all .5s ease}.llms-button-outline:disabled{opacity:.5}.llms-button-outline:hover,.llms-button-outline:active{color:#1d2327}.llms-button-outline:focus{color:#1d2327}.llms-button-outline.auto{width:auto}.llms-button-outline.full{display:block;text-align:center;width:100%}.llms-button-outline.square{padding:12px}.llms-donut{background-color:#f1f1f1;background-image:none;border-radius:50%;color:#ef476f;height:200px;overflow:hidden;position:relative;width:200px}.llms-donut:before,.llms-donut:after{content:" ";display:table}.llms-donut:after{clear:both}.llms-donut svg{overflow:visible !important;pointer-events:none;width:100%}.llms-donut svg path{fill:none;stroke-width:35px;stroke:#ef476f}.llms-donut.mini{height:36px;width:36px}.llms-donut.mini .percentage{font-size:10px}.llms-donut.small{height:100px;width:100px}.llms-donut.small .percentage{font-size:18px}.llms-donut.medium{height:130px;width:130px}.llms-donut.medium .percentage{font-size:26px}.llms-donut.large{height:260px;width:260px}.llms-donut.large .percentage{font-size:48px}.llms-donut .inside{-webkit-box-align:center;-ms-flex-align:center;align-items:center;background:#fff;border-radius:50%;-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;height:80%;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;left:50%;position:absolute;text-align:center;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%);width:80%;top:50%;z-index:3}.llms-donut .percentage{line-height:1.2;font-size:34px}.llms-donut .caption{font-size:50%}.lifterlms [data-tip],.lifterlms [data-title-default],.lifterlms [data-title-active],.llms-metabox [data-tip],.llms-metabox [data-title-default],.llms-metabox [data-title-active],.llms-mb-container [data-tip],.llms-mb-container [data-title-default],.llms-mb-container [data-title-active],.llms-quiz-wrapper [data-tip],.llms-quiz-wrapper [data-title-default],.llms-quiz-wrapper [data-title-active]{position:relative}.lifterlms [data-tip].tip--top-right:before,.lifterlms [data-title-default].tip--top-right:before,.lifterlms [data-title-active].tip--top-right:before,.llms-metabox [data-tip].tip--top-right:before,.llms-metabox [data-title-default].tip--top-right:before,.llms-metabox [data-title-active].tip--top-right:before,.llms-mb-container [data-tip].tip--top-right:before,.llms-mb-container [data-title-default].tip--top-right:before,.llms-mb-container [data-title-active].tip--top-right:before,.llms-quiz-wrapper [data-tip].tip--top-right:before,.llms-quiz-wrapper [data-title-default].tip--top-right:before,.llms-quiz-wrapper [data-title-active].tip--top-right:before{bottom:100%;left:-10px}.lifterlms [data-tip].tip--top-right:hover:before,.lifterlms [data-title-default].tip--top-right:hover:before,.lifterlms [data-title-active].tip--top-right:hover:before,.llms-metabox [data-tip].tip--top-right:hover:before,.llms-metabox [data-title-default].tip--top-right:hover:before,.llms-metabox [data-title-active].tip--top-right:hover:before,.llms-mb-container [data-tip].tip--top-right:hover:before,.llms-mb-container [data-title-default].tip--top-right:hover:before,.llms-mb-container [data-title-active].tip--top-right:hover:before,.llms-quiz-wrapper [data-tip].tip--top-right:hover:before,.llms-quiz-wrapper [data-title-default].tip--top-right:hover:before,.llms-quiz-wrapper [data-title-active].tip--top-right:hover:before{bottom:calc(100% + 6px)}.lifterlms [data-tip].tip--top-right:after,.lifterlms [data-title-default].tip--top-right:after,.lifterlms [data-title-active].tip--top-right:after,.llms-metabox [data-tip].tip--top-right:after,.llms-metabox [data-title-default].tip--top-right:after,.llms-metabox [data-title-active].tip--top-right:after,.llms-mb-container [data-tip].tip--top-right:after,.llms-mb-container [data-title-default].tip--top-right:after,.llms-mb-container [data-title-active].tip--top-right:after,.llms-quiz-wrapper [data-tip].tip--top-right:after,.llms-quiz-wrapper [data-title-default].tip--top-right:after,.llms-quiz-wrapper [data-title-active].tip--top-right:after{border-top-color:#444;left:6px;top:0}.lifterlms [data-tip].tip--top-right:hover:after,.lifterlms [data-title-default].tip--top-right:hover:after,.lifterlms [data-title-active].tip--top-right:hover:after,.llms-metabox [data-tip].tip--top-right:hover:after,.llms-metabox [data-title-default].tip--top-right:hover:after,.llms-metabox [data-title-active].tip--top-right:hover:after,.llms-mb-container [data-tip].tip--top-right:hover:after,.llms-mb-container [data-title-default].tip--top-right:hover:after,.llms-mb-container [data-title-active].tip--top-right:hover:after,.llms-quiz-wrapper [data-tip].tip--top-right:hover:after,.llms-quiz-wrapper [data-title-default].tip--top-right:hover:after,.llms-quiz-wrapper [data-title-active].tip--top-right:hover:after{top:-6px}.lifterlms [data-tip].tip--top-left:before,.lifterlms [data-title-default].tip--top-left:before,.lifterlms [data-title-active].tip--top-left:before,.llms-metabox [data-tip].tip--top-left:before,.llms-metabox [data-title-default].tip--top-left:before,.llms-metabox [data-title-active].tip--top-left:before,.llms-mb-container [data-tip].tip--top-left:before,.llms-mb-container [data-title-default].tip--top-left:before,.llms-mb-container [data-title-active].tip--top-left:before,.llms-quiz-wrapper [data-tip].tip--top-left:before,.llms-quiz-wrapper [data-title-default].tip--top-left:before,.llms-quiz-wrapper [data-title-active].tip--top-left:before{bottom:100%;right:-10px}.lifterlms [data-tip].tip--top-left:hover:before,.lifterlms [data-title-default].tip--top-left:hover:before,.lifterlms [data-title-active].tip--top-left:hover:before,.llms-metabox [data-tip].tip--top-left:hover:before,.llms-metabox [data-title-default].tip--top-left:hover:before,.llms-metabox [data-title-active].tip--top-left:hover:before,.llms-mb-container [data-tip].tip--top-left:hover:before,.llms-mb-container [data-title-default].tip--top-left:hover:before,.llms-mb-container [data-title-active].tip--top-left:hover:before,.llms-quiz-wrapper [data-tip].tip--top-left:hover:before,.llms-quiz-wrapper [data-title-default].tip--top-left:hover:before,.llms-quiz-wrapper [data-title-active].tip--top-left:hover:before{bottom:calc(100% + 6px)}.lifterlms [data-tip].tip--top-left:after,.lifterlms [data-title-default].tip--top-left:after,.lifterlms [data-title-active].tip--top-left:after,.llms-metabox [data-tip].tip--top-left:after,.llms-metabox [data-title-default].tip--top-left:after,.llms-metabox [data-title-active].tip--top-left:after,.llms-mb-container [data-tip].tip--top-left:after,.llms-mb-container [data-title-default].tip--top-left:after,.llms-mb-container [data-title-active].tip--top-left:after,.llms-quiz-wrapper [data-tip].tip--top-left:after,.llms-quiz-wrapper [data-title-default].tip--top-left:after,.llms-quiz-wrapper [data-title-active].tip--top-left:after{border-top-color:#444;right:6px;top:0}.lifterlms [data-tip].tip--top-left:hover:after,.lifterlms [data-title-default].tip--top-left:hover:after,.lifterlms [data-title-active].tip--top-left:hover:after,.llms-metabox [data-tip].tip--top-left:hover:after,.llms-metabox [data-title-default].tip--top-left:hover:after,.llms-metabox [data-title-active].tip--top-left:hover:after,.llms-mb-container [data-tip].tip--top-left:hover:after,.llms-mb-container [data-title-default].tip--top-left:hover:after,.llms-mb-container [data-title-active].tip--top-left:hover:after,.llms-quiz-wrapper [data-tip].tip--top-left:hover:after,.llms-quiz-wrapper [data-title-default].tip--top-left:hover:after,.llms-quiz-wrapper [data-title-active].tip--top-left:hover:after{top:-6px}.lifterlms [data-tip].tip--bottom-left:before,.lifterlms [data-title-default].tip--bottom-left:before,.lifterlms [data-title-active].tip--bottom-left:before,.llms-metabox [data-tip].tip--bottom-left:before,.llms-metabox [data-title-default].tip--bottom-left:before,.llms-metabox [data-title-active].tip--bottom-left:before,.llms-mb-container [data-tip].tip--bottom-left:before,.llms-mb-container [data-title-default].tip--bottom-left:before,.llms-mb-container [data-title-active].tip--bottom-left:before,.llms-quiz-wrapper [data-tip].tip--bottom-left:before,.llms-quiz-wrapper [data-title-default].tip--bottom-left:before,.llms-quiz-wrapper [data-title-active].tip--bottom-left:before{top:100%;right:-10px}.lifterlms [data-tip].tip--bottom-left:hover:before,.lifterlms [data-title-default].tip--bottom-left:hover:before,.lifterlms [data-title-active].tip--bottom-left:hover:before,.llms-metabox [data-tip].tip--bottom-left:hover:before,.llms-metabox [data-title-default].tip--bottom-left:hover:before,.llms-metabox [data-title-active].tip--bottom-left:hover:before,.llms-mb-container [data-tip].tip--bottom-left:hover:before,.llms-mb-container [data-title-default].tip--bottom-left:hover:before,.llms-mb-container [data-title-active].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-tip].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-title-default].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-title-active].tip--bottom-left:hover:before{top:calc(100% + 6px)}.lifterlms [data-tip].tip--bottom-left:after,.lifterlms [data-title-default].tip--bottom-left:after,.lifterlms [data-title-active].tip--bottom-left:after,.llms-metabox [data-tip].tip--bottom-left:after,.llms-metabox [data-title-default].tip--bottom-left:after,.llms-metabox [data-title-active].tip--bottom-left:after,.llms-mb-container [data-tip].tip--bottom-left:after,.llms-mb-container [data-title-default].tip--bottom-left:after,.llms-mb-container [data-title-active].tip--bottom-left:after,.llms-quiz-wrapper [data-tip].tip--bottom-left:after,.llms-quiz-wrapper [data-title-default].tip--bottom-left:after,.llms-quiz-wrapper [data-title-active].tip--bottom-left:after{border-bottom-color:#444;right:6px;bottom:0}.lifterlms [data-tip].tip--bottom-left:hover:after,.lifterlms [data-title-default].tip--bottom-left:hover:after,.lifterlms [data-title-active].tip--bottom-left:hover:after,.llms-metabox [data-tip].tip--bottom-left:hover:after,.llms-metabox [data-title-default].tip--bottom-left:hover:after,.llms-metabox [data-title-active].tip--bottom-left:hover:after,.llms-mb-container [data-tip].tip--bottom-left:hover:after,.llms-mb-container [data-title-default].tip--bottom-left:hover:after,.llms-mb-container [data-title-active].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-tip].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-title-default].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-title-active].tip--bottom-left:hover:after{bottom:-6px}.lifterlms [data-tip].tip--bottom-right:before,.lifterlms [data-title-default].tip--bottom-right:before,.lifterlms [data-title-active].tip--bottom-right:before,.llms-metabox [data-tip].tip--bottom-right:before,.llms-metabox [data-title-default].tip--bottom-right:before,.llms-metabox [data-title-active].tip--bottom-right:before,.llms-mb-container [data-tip].tip--bottom-right:before,.llms-mb-container [data-title-default].tip--bottom-right:before,.llms-mb-container [data-title-active].tip--bottom-right:before,.llms-quiz-wrapper [data-tip].tip--bottom-right:before,.llms-quiz-wrapper [data-title-default].tip--bottom-right:before,.llms-quiz-wrapper [data-title-active].tip--bottom-right:before{top:100%;left:-10px}.lifterlms [data-tip].tip--bottom-right:hover:before,.lifterlms [data-title-default].tip--bottom-right:hover:before,.lifterlms [data-title-active].tip--bottom-right:hover:before,.llms-metabox [data-tip].tip--bottom-right:hover:before,.llms-metabox [data-title-default].tip--bottom-right:hover:before,.llms-metabox [data-title-active].tip--bottom-right:hover:before,.llms-mb-container [data-tip].tip--bottom-right:hover:before,.llms-mb-container [data-title-default].tip--bottom-right:hover:before,.llms-mb-container [data-title-active].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-tip].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-title-default].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-title-active].tip--bottom-right:hover:before{top:calc(100% + 6px)}.lifterlms [data-tip].tip--bottom-right:after,.lifterlms [data-title-default].tip--bottom-right:after,.lifterlms [data-title-active].tip--bottom-right:after,.llms-metabox [data-tip].tip--bottom-right:after,.llms-metabox [data-title-default].tip--bottom-right:after,.llms-metabox [data-title-active].tip--bottom-right:after,.llms-mb-container [data-tip].tip--bottom-right:after,.llms-mb-container [data-title-default].tip--bottom-right:after,.llms-mb-container [data-title-active].tip--bottom-right:after,.llms-quiz-wrapper [data-tip].tip--bottom-right:after,.llms-quiz-wrapper [data-title-default].tip--bottom-right:after,.llms-quiz-wrapper [data-title-active].tip--bottom-right:after{border-bottom-color:#444;left:6px;bottom:0}.lifterlms [data-tip].tip--bottom-right:hover:after,.lifterlms [data-title-default].tip--bottom-right:hover:after,.lifterlms [data-title-active].tip--bottom-right:hover:after,.llms-metabox [data-tip].tip--bottom-right:hover:after,.llms-metabox [data-title-default].tip--bottom-right:hover:after,.llms-metabox [data-title-active].tip--bottom-right:hover:after,.llms-mb-container [data-tip].tip--bottom-right:hover:after,.llms-mb-container [data-title-default].tip--bottom-right:hover:after,.llms-mb-container [data-title-active].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-tip].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-title-default].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-title-active].tip--bottom-right:hover:after{bottom:-6px}.lifterlms [data-tip]:before,.lifterlms [data-title-default]:before,.lifterlms [data-title-active]:before,.llms-metabox [data-tip]:before,.llms-metabox [data-title-default]:before,.llms-metabox [data-title-active]:before,.llms-mb-container [data-tip]:before,.llms-mb-container [data-title-default]:before,.llms-mb-container [data-title-active]:before,.llms-quiz-wrapper [data-tip]:before,.llms-quiz-wrapper [data-title-default]:before,.llms-quiz-wrapper [data-title-active]:before{background:#444;border-radius:4px;color:#fff;font-size:13px;line-height:1.2;padding:8px;max-width:300px;width:-webkit-max-content;width:-moz-max-content;width:max-content}.lifterlms [data-tip]:after,.lifterlms [data-title-default]:after,.lifterlms [data-title-active]:after,.llms-metabox [data-tip]:after,.llms-metabox [data-title-default]:after,.llms-metabox [data-title-active]:after,.llms-mb-container [data-tip]:after,.llms-mb-container [data-title-default]:after,.llms-mb-container [data-title-active]:after,.llms-quiz-wrapper [data-tip]:after,.llms-quiz-wrapper [data-title-default]:after,.llms-quiz-wrapper [data-title-active]:after{content:"";border:6px solid rgba(0,0,0,0);height:0;width:0}.lifterlms [data-tip]:before,.lifterlms [data-tip]:after,.lifterlms [data-title-default]:before,.lifterlms [data-title-default]:after,.lifterlms [data-title-active]:before,.lifterlms [data-title-active]:after,.llms-metabox [data-tip]:before,.llms-metabox [data-tip]:after,.llms-metabox [data-title-default]:before,.llms-metabox [data-title-default]:after,.llms-metabox [data-title-active]:before,.llms-metabox [data-title-active]:after,.llms-mb-container [data-tip]:before,.llms-mb-container [data-tip]:after,.llms-mb-container [data-title-default]:before,.llms-mb-container [data-title-default]:after,.llms-mb-container [data-title-active]:before,.llms-mb-container [data-title-active]:after,.llms-quiz-wrapper [data-tip]:before,.llms-quiz-wrapper [data-tip]:after,.llms-quiz-wrapper [data-title-default]:before,.llms-quiz-wrapper [data-title-default]:after,.llms-quiz-wrapper [data-title-active]:before,.llms-quiz-wrapper [data-title-active]:after{opacity:0;-webkit-transition:all .2s .1s ease;transition:all .2s .1s ease;position:absolute;pointer-events:none;visibility:hidden}.lifterlms [data-tip]:hover:before,.lifterlms [data-tip]:hover:after,.lifterlms [data-title-default]:hover:before,.lifterlms [data-title-default]:hover:after,.lifterlms [data-title-active]:hover:before,.lifterlms [data-title-active]:hover:after,.llms-metabox [data-tip]:hover:before,.llms-metabox [data-tip]:hover:after,.llms-metabox [data-title-default]:hover:before,.llms-metabox [data-title-default]:hover:after,.llms-metabox [data-title-active]:hover:before,.llms-metabox [data-title-active]:hover:after,.llms-mb-container [data-tip]:hover:before,.llms-mb-container [data-tip]:hover:after,.llms-mb-container [data-title-default]:hover:before,.llms-mb-container [data-title-default]:hover:after,.llms-mb-container [data-title-active]:hover:before,.llms-mb-container [data-title-active]:hover:after,.llms-quiz-wrapper [data-tip]:hover:before,.llms-quiz-wrapper [data-tip]:hover:after,.llms-quiz-wrapper [data-title-default]:hover:before,.llms-quiz-wrapper [data-title-default]:hover:after,.llms-quiz-wrapper [data-title-active]:hover:before,.llms-quiz-wrapper [data-title-active]:hover:after{opacity:1;-webkit-transition:all .2s .6s ease;transition:all .2s .6s ease;visibility:visible;z-index:99999999}.lifterlms [data-tip]:before,.llms-metabox [data-tip]:before,.llms-mb-container [data-tip]:before,.llms-quiz-wrapper [data-tip]:before{content:attr(data-tip)}.lifterlms [data-tip].active:before,.llms-metabox [data-tip].active:before,.llms-mb-container [data-tip].active:before,.llms-quiz-wrapper [data-tip].active:before{content:attr(data-tip-active)}.llms-membership-image{display:block;margin:0 auto}.llms-course-image{display:block;margin:0 auto;max-width:100%}.llms-featured-image{display:block;margin:0 auto}.llms-image-thumb{width:150px}.llms-video-wrapper .center-video{height:auto;max-width:100%;overflow:hidden;position:relative;padding-top:56.25%;text-align:center}.llms-video-wrapper .center-video>.wp-video,.llms-video-wrapper .center-video .fluid-width-video-wrapper,.llms-video-wrapper .center-video iframe,.llms-video-wrapper .center-video object,.llms-video-wrapper .center-video embed{height:100%;left:0;position:absolute;top:0;width:100%}.llms-video-wrapper .center-video>.wp-video{width:100% !important}.llms-video-wrapper .center-video .fluid-width-video-wrapper{padding-top:0 !important}.clear{clear:both;width:100%}.llms-featured-image{text-align:center}#main-content .llms-payment-options p{margin:0;font-size:16px}.llms-option{display:block;position:relative;margin:20px 0;padding-left:40px;font-size:16px}.llms-option label{cursor:pointer;position:static}.llms-option:first-child{margin-top:0}.llms-option:last-child{margin-bottom:0}#main-content .llms-option:last-child{margin-bottom:0}.llms-option input[type=radio]{display:block;position:absolute;top:3px;left:0;z-index:0}.llms-option input[type=radio]{display:inline-block}.llms-option input[type=radio]+label span.llms-radio{display:none}.llms-option input[type=radio]+label span.llms-radio{-webkit-appearance:none;-moz-appearance:none;appearance:none;z-index:20;position:absolute;top:0;left:-2px;display:inline-block;width:24px;height:24px;border-radius:50%;cursor:pointer;vertical-align:middle;-webkit-box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.5) 0 0 0 1px;box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.5) 0 0 0 1px;background:#efefef;background-image:radial-gradient(ellipse at center, #e5554e 0%, #e5554e 40%, #efefef 45%);background-repeat:no-repeat;-webkit-transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);transition:background-position .15s cubic-bezier(0.8, 0, 1, 1)}.llms-option input[type=radio]:checked+label span.llms-radio{-webkit-transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1)}.llms-option input[type=radio]+label span.llms-radio{background-position:-24px 0}.llms-option input[type=radio]:checked+label span.llms-radio{background-position:0 0}.llms-option input[type=submit]{border:none;background:#e5554e;color:#fff;font-size:20px;padding:10px 0;border-radius:3px;cursor:pointer;width:100%}.llms-styled-text{padding:14px 0}.llms-notice-box{border-radius:3px;z-index:10;margin:10px 0;padding:15px 20px;border:1px solid #ccc;list-style-type:none;width:100%;overflow:auto}.llms-notice-box input[type=text]{height:auto}.llms-notice-box .col-1-1{width:100%}.llms-notice-box .col-1-1 input[type=text]{width:100%}.llms-notice-box .col-1-2{width:50%;float:left}@media screen and (max-width: 768px){.llms-notice-box .col-1-2{width:100%}}.llms-notice-box .col-1-3{width:33%;float:left;margin-right:10px}.llms-notice-box .col-1-4{width:25%;float:left;margin-right:10px}@media screen and (max-width: 768px){.llms-notice-box .col-1-4{width:100%}}.llms-notice-box .col-1-6{width:16.6%;float:left;margin-right:10px}.llms-notice-box .col-1-8{width:11%;float:right}.llms-notice-box .llms-pad-right{padding-right:10px}@media screen and (max-width: 768px){.llms-notice-box .llms-pad-right{padding-right:0}}input[type=text].cc_cvv,#cc_cvv{margin-right:0;width:23%;float:right}.llms-clear-box{border-radius:3px;z-index:10;margin:10px 0;padding:15px 20px;list-style-type:none;width:100%;overflow:auto}.llms-price-label{font-weight:normal}.llms-final-price{font-weight:bold;float:right}.llms-center-content{text-align:center}.llms-input-text{background-color:#fff;border:1px solid #ddd;color:#333;font-size:18px;font-weight:300;padding:16px;width:100%}.llms-price{margin-bottom:0;font-weight:bold}.llms-price-loop{margin-bottom:0;font-weight:bold}.courses .entry{padding:0}.list-view .site-content .llms-course-list .hentry,.list-view .site-content .llms-membership-list .hentry{border-top:0;padding-top:0}.llms-content{width:100%}.llms-lesson-button-wrapper{width:100%;display:block;clear:both;text-align:center}.llms-template-wrapper{width:100%;display:block;clear:both}.llms-button-wrapper{width:100%;display:block;clear:both;text-align:center}.llms-styled-select{border:1px solid #ccc;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:3px;overflow:hidden;position:relative}.llms-styled-select,.llms-styled-select select{width:100%}select:focus{outline:none}.llms-styled-select select{height:34px;padding:5px 0 5px 5px;background:rgba(0,0,0,0);border:none;-webkit-appearance:none;font-size:16px;color:#444}@-moz-document url-prefix(){.--ms-styled-select select{width:110%}}.llms-styled-select .fa-sort-desc{position:absolute;top:0;right:12px;font-size:24px;color:#ccc}select::-ms-expand{display:none}_:-o-prefocus .llms-styled-select,.selector .llms-styled-select{background:none}.llms-form-item-wrapper{margin-bottom:1em}.llms-progress-circle{position:relative;width:200px;height:200px;float:left}.llms-progress-circle-count{top:27%;position:absolute;width:94%;text-align:center;color:#666;font-size:44px}.llms-progress-circle svg{position:absolute;width:200px;height:200px}.llms-progress-circle circle{fill:rgba(0,0,0,0)}svg .llms-background-circle{fill:rgba(0,0,0,0);stroke-width:10px;stroke:#f1f2f1;stroke-dasharray:430}svg .llms-animated-circle{fill:rgba(0,0,0,0);stroke-width:10px;stroke:#e5554e;stroke-dasharray:430;stroke-dashoffset:410}.llms-widget-syllabus .llms-lesson.current-lesson .lesson-title{font-weight:700}.llms-widget-syllabus .llms-lesson-complete,.llms-widget-syllabus .lesson-complete-placeholder{font-size:1.2em;margin-right:6px;color:#ccc}.llms-widget-syllabus .llms-lesson-complete.done,.llms-widget-syllabus .lesson-complete-placeholder.done{color:#e5554e}.llms-widget-syllabus .section-title{font-weight:bold}.llms-widget-syllabus .lesson-title a{text-decoration:none}.llms-widget-syllabus .lesson-title a:hover{text-decoration:none !important}.llms-widget-syllabus .lesson-title.done a{color:#999;text-decoration:line-through}.llms-widget-syllabus ul{list-style-type:none}.llms-widget-syllabus ul li{list-style-type:none}.llms-widget-syllabus ul li ul li{margin:0 0 2px 0;padding:0}.llms-remove-coupon{float:right}.llms-lesson-link-locked,.llms-lesson-link-locked:hover{background:#f1f1f1;-webkit-box-shadow:0 1px 2px 0 rgba(1,1,1,.4);box-shadow:0 1px 2px 0 rgba(1,1,1,.4);display:block;color:#a6a6a6;min-height:85px;padding:15px;text-decoration:none;position:relative}.llms-lesson-preview.is-complete .llms-lesson-link-locked{padding-left:75px}.llms-lesson-tooltip{display:none;position:absolute;color:#000;background-color:silver;padding:.25em;border-radius:2px;z-index:100;top:0;left:50%;text-align:center;-webkit-transform:translateX(-50%) translateY(-100%);transform:translateX(-50%) translateY(-100%)}.llms-lesson-tooltip:after{content:"";width:0;height:0;border-top:8px solid silver;border-left:8px solid rgba(0,0,0,0);border-right:8px solid rgba(0,0,0,0);position:absolute;bottom:-8px;left:50%;-webkit-transform:translateX(-50%);transform:translateX(-50%)}.llms-lesson-tooltip.active{display:inline-block}.llms-loop-list{list-style:none;margin:0 -10px;padding:0}@media all and (min-width: 600px){.llms-loop-list.cols-1 .llms-loop-item{width:100%}.llms-loop-list.cols-2 .llms-loop-item{width:50%}.llms-loop-list.cols-3 .llms-loop-item{width:33.3333333333%}.llms-loop-list.cols-4 .llms-loop-item{width:25%}.llms-loop-list.cols-5 .llms-loop-item{width:20%}.llms-loop-list.cols-6 .llms-loop-item{width:16.6666666667%}}.llms-loop-item{float:left;list-style:none;margin:0;padding:0;width:100%}.llms-loop-item-content{background:#f1f1f1;padding-bottom:10px;margin:10px}.llms-loop-item-content:hover{background:#eaeaea}.llms-loop-item-content .llms-loop-link{color:#212121;display:block}.llms-loop-item-content .llms-loop-link:visited{color:#212121}.llms-loop-item-content .llms-featured-image{display:block;max-width:100%}.llms-loop-item-content .llms-loop-title{margin-top:5px}.llms-loop-item-content .llms-loop-title:hover{color:#2295ff}.llms-loop-item-content .llms-meta,.llms-loop-item-content .llms-author,.llms-loop-item-content .llms-loop-title{padding:0 10px}.llms-loop-item-content .llms-meta,.llms-loop-item-content .llms-author{color:#444;display:block;font-size:13px;margin-bottom:3px}.llms-loop-item-content .llms-meta:last-child,.llms-loop-item-content .llms-author:last-child{margin-bottom:0}.llms-loop-item-content .llms-featured-img-wrap{overflow:hidden}.llms-loop-item-content p{margin-bottom:0}.llms-loop-item-content .llms-progress{margin:0;height:.4em}.llms-loop-item-content .llms-progress .progress__indicator{display:none}.llms-loop-item-content .llms-progress .llms-progress-bar{background-color:#f6f6f6;right:0;top:0}.course .llms-meta-info{margin:20px 0}.course .llms-meta-info .llms-meta-title{margin-bottom:5px}.course .llms-meta-info .llms-meta p{margin-bottom:0}.course .llms-meta-info .llms-meta span{font-weight:700}.course .llms-course-progress{margin:40px auto;max-width:480px;text-align:center}.llms-syllabus-wrapper{margin:15px;text-align:center}.llms-syllabus-wrapper .llms-section-title{margin:25px 0 0}.llms-course-navigation .llms-prev-lesson,.llms-course-navigation .llms-next-lesson,.llms-course-navigation .llms-back-to-course{width:49%}.llms-course-navigation .llms-prev-lesson,.llms-course-navigation .llms-back-to-course{float:left;margin-right:.5%}.llms-course-navigation .llms-next-lesson,.llms-course-navigation .llms-prev-lesson+.llms-back-to-course{float:right;margin-left:.5%}.llms-lesson-preview{display:inline-block;margin-top:15px;max-width:100%;position:relative;width:480px}.llms-lesson-preview .llms-lesson-link{background:#f1f1f1;color:#212121;display:block;padding:15px;text-decoration:none}.llms-lesson-preview .llms-lesson-link:before,.llms-lesson-preview .llms-lesson-link:after{content:" ";display:table}.llms-lesson-preview .llms-lesson-link:after{clear:both}.llms-lesson-preview .llms-lesson-link:hover{background:#eaeaea}.llms-lesson-preview .llms-lesson-link:visited{color:#212121}.llms-lesson-preview .llms-lesson-thumbnail{margin-bottom:10px}.llms-lesson-preview .llms-lesson-thumbnail img{display:block;width:100%}.llms-lesson-preview .llms-pre-text{text-align:left}.llms-lesson-preview .llms-lesson-title{font-weight:700;margin:0 auto 10px;text-align:left}.llms-lesson-preview .llms-lesson-title:last-child{margin-bottom:0}.llms-lesson-preview .llms-lesson-excerpt{text-align:left}.llms-lesson-preview .llms-main{float:left;width:100%}.llms-lesson-preview .llms-extra{float:right;width:15%}.llms-lesson-preview .llms-extra+.llms-main{width:85%}.llms-lesson-preview .llms-lesson-counter,.llms-lesson-preview .llms-free-lesson-svg,.llms-lesson-preview .llms-lesson-complete,.llms-lesson-preview .llms-lesson-complete-placeholder{display:block;font-size:32px;margin-bottom:15px}.llms-lesson-preview.is-free .llms-lesson-complete,.llms-lesson-preview.is-complete .llms-lesson-complete{color:#2295ff}.llms-lesson-preview .llms-icon-free{background:#2295ff;border-radius:4px;color:#f1f1f1;display:inline-block;padding:5px 6px 4px;line-height:1;font-size:14px}.llms-lesson-preview.is-incomplete .llms-lesson-complete{color:#cacaca}.llms-lesson-preview .llms-lesson-counter{font-size:16px;line-height:1}.llms-lesson-preview .llms-free-lesson-svg{fill:currentColor;height:23px;width:50px}.llms-lesson-preview p{margin-bottom:0}.llms-progress{clear:both;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:reverse;-ms-flex-direction:row-reverse;flex-direction:row-reverse;position:relative;height:1em;width:100%;margin:15px 0}.llms-progress .llms-progress-bar{background-color:#f1f2f1;position:relative;height:.4em;top:.3em;width:100%}.llms-progress .progress-bar-complete{background-color:#ef476f;height:100%}.progress__indicator{float:right;text-align:right;height:1em;line-height:1em;margin-left:5px;white-space:nowrap}.llms-author .name{margin-left:5px}.llms-author .label{margin-left:5px}.llms-author .avatar{border-radius:50%}.llms-author .bio{margin-top:5px}.llms-instructor-info .llms-instructors .llms-col:first-child .llms-author{margin-left:0}.llms-instructor-info .llms-instructors .llms-col:last-child .llms-author{margin-right:0}.llms-instructor-info .llms-instructors .llms-author{background:#f5f5f5;border-top:4px solid #2295ff;text-align:center;margin:45px 5px 5px;padding:0 10px 10px}.llms-instructor-info .llms-instructors .llms-author .avatar{background:#2295ff;border:4px solid #2295ff;display:block;margin:-35px auto 10px}.llms-instructor-info .llms-instructors .llms-author .llms-author-info{display:block}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.name{font-weight:700}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.label{font-size:85%}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.bio{font-size:90%;margin-bottom:0}.llms_review{margin:20px 0px;padding:10px}.llms_review h5{font-size:17px;margin:3px 0px}.llms_review h6{font-size:13px}.llms_review p{font-size:15px}.review_box [type=text]{margin:10px 0px}.review_box h5{color:red;display:none}.review_box+.thank_you_box{display:none}.llms-notice{background:rgba(34,149,255,.3);border-color:#2295ff;border-style:solid;border-width:3px;padding:10px;margin-bottom:10px}.llms-notice p:last-child,.llms-notice ul:last-child{margin-bottom:0}.llms-notice li{list-style-type:none}.llms-notice.llms-debug{background:rgba(202,202,202,.3);border-color:#cacaca}.llms-notice.llms-error{background:rgba(229,85,78,.3);border-color:#e5554e}.llms-notice.llms-success{background:rgba(131,195,115,.3);border-color:#83c373}.entry-content .llms-notice{margin:0 0 10px}.entry-content .llms-notice li{list-style-type:none}ul.llms-achievements-loop,.lifterlms ul.llms-achievements-loop,ul.llms-certificates-loop,.lifterlms ul.llms-certificates-loop{list-style-type:none;margin:0 -10px;padding:0}ul.llms-achievements-loop:before,ul.llms-achievements-loop:after,.lifterlms ul.llms-achievements-loop:before,.lifterlms ul.llms-achievements-loop:after,ul.llms-certificates-loop:before,ul.llms-certificates-loop:after,.lifterlms ul.llms-certificates-loop:before,.lifterlms ul.llms-certificates-loop:after{content:" ";display:table}ul.llms-achievements-loop:after,.lifterlms ul.llms-achievements-loop:after,ul.llms-certificates-loop:after,.lifterlms ul.llms-certificates-loop:after{clear:both}ul.llms-achievements-loop li.llms-achievement-loop-item,ul.llms-achievements-loop li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop li.llms-certificate-loop-item,ul.llms-certificates-loop li.llms-achievement-loop-item,ul.llms-certificates-loop li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop li.llms-certificate-loop-item{-webkit-box-sizing:border-box;box-sizing:border-box;display:block;float:left;list-style-type:none;margin:0;padding:10px;width:100%}@media all and (min-width: 600px){ul.llms-achievements-loop.loop-cols-1 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-1 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-1 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-1 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-1 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-1 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-1 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-1 li.llms-certificate-loop-item{width:100%}ul.llms-achievements-loop.loop-cols-2 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-2 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-2 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-2 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-2 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-2 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-2 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-2 li.llms-certificate-loop-item{width:50%}ul.llms-achievements-loop.loop-cols-3 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-3 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-3 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-3 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-3 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-3 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-3 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-3 li.llms-certificate-loop-item{width:33.3333333333%}ul.llms-achievements-loop.loop-cols-4 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-4 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-4 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-4 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-4 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-4 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-4 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-4 li.llms-certificate-loop-item{width:25%}ul.llms-achievements-loop.loop-cols-5 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-5 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-5 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-5 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-5 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-5 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-5 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-5 li.llms-certificate-loop-item{width:20%}}.llms-achievement,.llms-certificate{background:#f1f1f1;border:none;color:inherit;display:block;text-decoration:none;width:100%}.llms-achievement:hover,.llms-certificate:hover{background:#eaeaea}.llms-achievement .llms-achievement-img,.llms-certificate .llms-achievement-img{display:block;margin:0;width:100%}.llms-achievement .llms-achievement-title,.llms-certificate .llms-achievement-title{font-size:16px;margin:0;padding:10px;text-align:center}.llms-achievement .llms-certificate-title,.llms-certificate .llms-certificate-title{font-size:16px;margin:0;padding:0 0 10px}.llms-achievement .llms-achievement-info,.llms-achievement .llms-achievement-date,.llms-certificate .llms-achievement-info,.llms-certificate .llms-achievement-date{display:none}.llms-achievement .llms-achievement-content,.llms-certificate .llms-achievement-content{padding:20px}.llms-achievement .llms-achievement-content:empty,.llms-certificate .llms-achievement-content:empty{padding:0}.llms-achievement .llms-achievement-content *:last-child,.llms-certificate .llms-achievement-content *:last-child{margin-bottom:0}.llms-certificate{border:4px double #f1f1f1;padding:20px 10px;background:#fff;text-align:center}.llms-certificate:hover{background:#fff;border-color:#eaeaea}.llms-achievement-modal .llms-achievement{background:#fff}.llms-achievement-modal .llms-achievement-info{display:block}.llms-achievement-modal .llms-achievement-title{display:none}.llms-notification{background:#fff;-webkit-box-shadow:0 1px 2px -2px #333,0 1px 1px -1px #333;box-shadow:0 1px 2px -2px #333,0 1px 1px -1px #333;border-top:4px solid #2295ff;opacity:0;padding:12px;position:fixed;right:-800px;top:24px;-webkit-transition:opacity .4s ease-in-out,right .4s ease-in-out;transition:opacity .4s ease-in-out,right .4s ease-in-out;visibility:hidden;width:auto;z-index:9999999}.llms-notification:before,.llms-notification:after{content:" ";display:table}.llms-notification:after{clear:both}.llms-notification.visible{left:12px;opacity:1;right:12px;-webkit-transition:opacity .4s ease-in-out,right .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,-webkit-transform .2s ease-in-out;transition:opacity .4s ease-in-out,right .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,-webkit-transform .2s ease-in-out;transition:opacity .4s ease-in-out,right .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,transform .2s ease-in-out;transition:opacity .4s ease-in-out,right .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,transform .2s ease-in-out,-webkit-transform .2s ease-in-out;visibility:visible}.llms-notification.visible:hover .llms-notification-dismiss{opacity:1}.llms-notification .llms-notification-content{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex}.llms-notification .llms-notification-main{-ms-flex-item-align:start;align-self:flex-start;-webkit-box-flex:4;-ms-flex:4;flex:4;-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2}.llms-notification .llms-notification-title{font-size:18px;margin:0}.llms-notification .llms-notification-body{font-size:14px;line-height:1.4}.llms-notification .llms-notification-body p,.llms-notification .llms-notification-body li{font-size:inherit}.llms-notification .llms-notification-body p{margin-bottom:8px}.llms-notification .llms-notification-body .llms-mini-cert{background:#f6f6f6;border:1px solid #d0d0d0;-webkit-box-shadow:inset 0 0 0 3px #fefefe,inset 0 0 0 4px #dedede;box-shadow:inset 0 0 0 3px #fefefe,inset 0 0 0 4px #dedede;padding:16px 16px 24px;margin-top:12px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert-title{font-size:16px;font-weight:700;margin:12px auto;text-align:center}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body{width:100%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(1){width:65%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(2){width:35%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(3){width:85%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(4){width:75%;margin-top:18px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(5){width:70%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(6){margin-left:12px;margin-bottom:-24px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(7){width:65%;margin-right:12px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--mock-line{border-radius:2px;height:8px;background:#b0b0b0;background-image:-webkit-gradient(linear, left top, right top, from(#b0b0b0), color-stop(20%, #a0a0a0), color-stop(40%, #b0b0b0), to(#b0b0b0));background-image:linear-gradient(to right, #b0b0b0 0%, #a0a0a0 20%, #b0b0b0 40%, #b0b0b0 100%);background-repeat:no-repeat;margin:4px auto}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--mock-dot{background:#b0b0b0;border-radius:50%;display:inline-block;content:"";height:24px;width:24px}.llms-notification .llms-notification-body .llms-mini-cert p{margin-bottom:0}.llms-notification .llms-notification-aside{-ms-flex-item-align:start;align-self:flex-start;-webkit-box-flex:1;-ms-flex:1;flex:1;margin-right:12px;-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1}.llms-notification .llms-notification-icon{display:block;max-width:64px}.llms-notification .llms-notification-footer{border-top:1px solid #e5e5e5;font-size:12px;margin-top:12px;padding:6px 6px 0;text-align:right}.llms-notification .llms-notification-dismiss{color:#e5554e;cursor:pointer;font-size:22px;position:absolute;right:10px;top:8px;-webkit-transition:opacity .4s ease-in-out;transition:opacity .4s ease-in-out}.llms-sd-notification-center .llms-notification-list,.llms-sd-notification-center .llms-notification-list-item{list-style-type:none;margin:0;padding:0}.llms-sd-notification-center .llms-notification-list-item:hover .llms-notification{background:#fcfcfc}.llms-sd-notification-center .llms-notification{opacity:1;border-top:1px solid #e5e5e5;left:auto;padding:24px;position:relative;right:auto;top:auto;visibility:visible;width:auto}.llms-sd-notification-center .llms-notification .llms-notification-aside{max-width:64px}.llms-sd-notification-center .llms-notification .llms-notification-footer{border:none;padding:0;text-align:left}.llms-sd-notification-center .llms-notification .llms-progress{display:none !important}.llms-sd-notification-center .llms-notification .llms-notification-date{color:#515151;float:left;margin-right:6px}.llms-sd-notification-center .llms-notification .llms-mini-cert{margin:0 auto;max-width:380px}@media all and (min-width: 480px){.llms-notification{right:-800px;width:360px}.llms-notification.visible{left:auto;right:24px}.llms-notification .llms-notification-dismiss{opacity:0}}.llms-pagination ul{list-style-type:none}.llms-pagination ul li{float:left}.llms-pagination ul li a{border-bottom:0;text-decoration:none}.llms-pagination ul li .page-numbers{padding:.5em;text-decoration:underline}.llms-pagination ul li .page-numbers.current{text-decoration:none}.llms-tooltip{background:#2a2a2a;border-radius:4px;color:#fff;font-size:14px;line-height:1.2;opacity:0;top:-20px;padding:8px 12px;left:50%;position:absolute;pointer-events:none;-webkit-transform:translateX(-50%);transform:translateX(-50%);-webkit-transition:opacity .2s ease,top .2s ease;transition:opacity .2s ease,top .2s ease;max-width:320px}.llms-tooltip.show{top:-28px;opacity:1}.llms-tooltip:after{bottom:-8px;border-top:8px solid #2a2a2a;border-left:8px solid rgba(0,0,0,0);border-right:8px solid rgba(0,0,0,0);content:"";height:0;left:50%;position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%);width:0}.webui-popover-title{font-size:initial;font-weight:initial;line-height:initial}.webui-popover-inverse .webui-popover-inner .close{color:#fff;opacity:.6;text-shadow:none}.webui-popover-inverse .webui-popover-inner .close:hover{opacity:.8}.webui-popover-inverse .webui-popover-content a{color:#fff;text-decoration:underline}.webui-popover-inverse .webui-popover-content a:hover{text-decoration:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results{margin:0;padding:0;list-style-type:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question{background:#efefef;margin:0 0 10px;position:relative;list-style-type:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer{color:inherit;display:block;padding:10px 35px 10px 10px;text-decoration:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:before,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:after{content:" ";display:table}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:after{clear:both}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.correct,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.incorrect{background:rgba(255,146,43,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.correct .llms-status-icon,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.incorrect .llms-status-icon{background-color:#ff922b}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.correct{background:rgba(131,195,115,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.correct .llms-status-icon{background-color:#83c373}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.incorrect{background:rgba(229,85,78,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.incorrect .llms-status-icon{background-color:#e5554e}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question pre{overflow:auto}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-question-title{float:left;margin:0;line-height:1}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-points{float:right;line-height:1}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-status-icon-tip{position:absolute;right:-12px;top:-2px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-status-icon{color:rgba(255,255,255,.65);border-radius:50%;font-size:30px;height:40px;line-height:40px;text-align:center;width:40px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main{display:none;padding:0 10px 10px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-results-label{font-weight:700;margin-bottom:10px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers{margin:0;padding:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer{padding:0;margin:0 0 0 30px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer:only-child{list-style-type:none;margin-left:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main img{height:auto;max-width:200px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-attempt-answer-section{border-top:2px solid rgba(255,255,255,.5);margin-top:20px;padding-top:20px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-attempt-answer-section:first-child{border-top:none;margin-top:0;padding-top:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_choice ul.llms-quiz-attempt-answers,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_reorder ul.llms-quiz-attempt-answers{list-style-type:none;margin:0;padding:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_choice ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_reorder ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer{display:inline-block;list-style-type:none;margin:0;padding:5px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--removed{opacity:.5}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--removed .llms-question-title{font-style:italic;font-weight:normal}.single-llms_quiz .llms-return{margin-bottom:10px}.single-llms_quiz .llms-quiz-results:before,.single-llms_quiz .llms-quiz-results:after{content:" ";display:table}.single-llms_quiz .llms-quiz-results:after{clear:both}.single-llms_quiz .llms-quiz-results .llms-donut.passing{color:#83c373}.single-llms_quiz .llms-quiz-results .llms-donut.passing svg path{stroke:#83c373}.single-llms_quiz .llms-quiz-results .llms-donut.pending{color:#555}.single-llms_quiz .llms-quiz-results .llms-donut.pending svg path{stroke:#555}.single-llms_quiz .llms-quiz-results .llms-donut.failing{color:#e5554e}.single-llms_quiz .llms-quiz-results .llms-donut.failing svg path{stroke:#e5554e}.single-llms_quiz .llms-quiz-results .llms-quiz-results-aside,.single-llms_quiz .llms-quiz-results .llms-quiz-results-main,.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{margin-bottom:20px}@media all and (min-width: 600px){.single-llms_quiz .llms-quiz-results .llms-quiz-results-aside{float:left;width:220px}.single-llms_quiz .llms-quiz-results .llms-quiz-results-main,.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{float:right;width:calc(100% - 300px)}.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{clear:right}}.single-llms_quiz ul.llms-quiz-meta-info,.single-llms_quiz ul.llms-quiz-meta-info li{list-style-type:none;margin:0;padding:0}.single-llms_quiz ul.llms-quiz-meta-info{margin-bottom:10px}.single-llms_quiz .llms-quiz-buttons{margin-top:10px;text-align:left}.single-llms_quiz .llms-quiz-buttons form{display:inline-block}.llms-quiz-question-wrapper{min-height:140px;position:relative}.llms-quiz-question-wrapper .llms-quiz-loading{bottom:20px;left:0;position:absolute;right:0;text-align:center;z-index:1}.llms-quiz-ui{background:#fcfcfc;padding:20px;position:relative}.llms-quiz-ui .llms-quiz-header{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex;margin:0 0 30px}.llms-quiz-ui .llms-progress{background-color:#f1f2f1;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;height:8px;margin:0;overflow:hidden}.llms-quiz-ui .llms-progress .progress-bar-complete{-webkit-transition:width .3s ease-in;transition:width .3s ease-in;width:0}.llms-quiz-ui .llms-error{background:#e5554e;border-radius:4px;color:#fff;margin:10px 0;padding:10px}.llms-quiz-ui .llms-error:before,.llms-quiz-ui .llms-error:after{content:" ";display:table}.llms-quiz-ui .llms-error:after{clear:both}.llms-quiz-ui .llms-error a{color:rgba(255,255,255,.6);float:right;font-size:22px;line-height:1;text-decoration:none}.llms-quiz-ui .llms-quiz-counter{display:none;color:#6a6a6a;float:right;font-size:18px}.llms-quiz-ui .llms-quiz-counter .llms-sep{margin:0 5px}.llms-quiz-ui .llms-quiz-nav{margin-top:20px}.llms-quiz-ui .llms-quiz-nav button{margin:0 10px 0 0}.llms-question-wrapper .llms-question-text{font-size:30px;font-weight:400;margin-bottom:15px}.llms-question-wrapper ol.llms-question-choices{list-style-type:none;margin:0;padding:0}.llms-question-wrapper ol.llms-question-choices li.llms-choice{border-bottom:1px solid #e8e8e8;margin:0;padding:0;position:relative}.llms-question-wrapper ol.llms-question-choices li.llms-choice:last-child{border-bottom:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture{border-bottom:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture label{display:inline-block;padding:0}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-marker{bottom:10px;margin:0;position:absolute;right:10px}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-choice-image{margin:2px;padding:20px;-webkit-transition:background .4s ease;transition:background .4s ease}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-choice-image img{display:block;width:100%}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture input:checked~.llms-choice-image{background:#efefef}.llms-question-wrapper ol.llms-question-choices li.llms-choice input{display:none;left:0;pointer-events:none;position:absolute;top:0;visibility:hidden}.llms-question-wrapper ol.llms-question-choices li.llms-choice label{display:block;margin:0;padding:10px 20px;position:relative}.llms-question-wrapper ol.llms-question-choices li.llms-choice label.hovered .llms-marker:not(.type--lister) .iterator{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice label.hovered .llms-marker:not(.type--lister) .fa{display:inline}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker{background:#f0f0f0;display:inline-block;font-size:20px;height:40px;line-height:40px;margin-right:10px;text-align:center;-webkit-transition:all .2s ease;transition:all .2s ease;vertical-align:middle;width:40px}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker .fa{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--lister,.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--checkbox{border-radius:4px}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--radio{border-radius:50%}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker{background:#ef476f;color:#fff}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker .iterator{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker .fa{display:inline}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-choice-text{display:inline-block;font-size:18px;font-weight:400;line-height:1.6;margin-bottom:0;vertical-align:middle;width:calc(100% - 60px)}.llms-quiz-timer{background:#fff;border:1px solid #83c373;border-radius:4px;color:#83c373;float:right;font-size:18px;line-height:1;margin-left:20px;padding:8px 12px;position:relative;white-space:nowrap;z-index:1}.llms-quiz-timer.color-half{border-color:#ff922b;color:#ff922b}.llms-quiz-timer.color-empty{border-color:#e5554e;color:#e5554e}.llms-quiz-timer .llms-tiles{display:inline-block;margin-left:5px}.voucher-expand{display:none}@media all and (min-width: 600px){.llms-access-plans.cols-1 .llms-access-plan{width:100%}.llms-access-plans.cols-2 .llms-access-plan{width:50%}.llms-access-plans.cols-3 .llms-access-plan{width:33.3333333333%}.llms-access-plans.cols-4 .llms-access-plan{width:25%}.llms-access-plans.cols-5 .llms-access-plan{width:20%}}.llms-free-enroll-form{margin-bottom:0}.llms-access-plan{-webkit-box-sizing:border-box;box-sizing:border-box;float:left;text-align:center;width:100%}.llms-access-plan .llms-access-plan-footer,.llms-access-plan .llms-access-plan-content{background:#f1f1f1}.llms-access-plan.featured .llms-access-plan-featured{background:#4ba9ff}.llms-access-plan.featured .llms-access-plan-footer,.llms-access-plan.featured .llms-access-plan-content{border-left:3px solid #2295ff;border-right:3px solid #2295ff}.llms-access-plan.featured .llms-access-plan-footer{border-bottom-color:#2295ff}.llms-access-plan.on-sale .price-regular{text-decoration:line-through}.llms-access-plan .stamp{background:#2295ff;color:#fff;font-size:11px;font-style:normal;font-weight:300;padding:2px 3px;vertical-align:top}.llms-access-plan .llms-access-plan-restrictions ul{margin:0}.llms-access-plan-featured{color:#fff;font-size:14px;font-weight:400;margin:0 2px 0 2px}.llms-access-plan-content{margin:0 2px 0}.llms-access-plan-content .llms-access-plan-pricing{padding:10px 0 0}.llms-access-plan-title{background:#2295ff;color:#fff;margin-bottom:0;padding:10px}.llms-access-plan-pricing .llms-price-currency-symbol{font-size:14px;vertical-align:top}.llms-access-plan-price{font-size:18px;font-variant:small-caps;line-height:20px}.llms-access-plan-price .lifterlms-price{font-weight:700}.llms-access-plan-price.sale{padding:5px 0;border-top:1px solid #d0d0d0;border-bottom:1px solid #d0d0d0}.llms-access-plan-trial,.llms-access-plan-schedule,.llms-access-plan-sale-end,.llms-access-plan-expiration{font-size:15px;font-variant:small-caps;line-height:1.2}.llms-access-plan-description{font-size:16px;padding:10px 10px 0}.llms-access-plan-description ul{margin:0}.llms-access-plan-description ul li{border-bottom:1px solid #d0d0d0;list-style-type:none}.llms-access-plan-description ul li:last-child{border-bottom:none}.llms-access-plan-description div:last-child,.llms-access-plan-description img:last-child,.llms-access-plan-description p:last-child,.llms-access-plan-description ul:last-child,.llms-access-plan-description li:last-child{margin-bottom:0}.llms-access-plan-restrictions .stamp{vertical-align:baseline}.llms-access-plan-restrictions ul{margin:0}.llms-access-plan-restrictions ul li{font-size:12px;line-height:14px;list-style-type:none}.llms-access-plan-restrictions a{color:#f8954f}.llms-access-plan-restrictions a:hover{color:#f67d28}.llms-access-plan-footer{border-bottom:3px solid #f1f1f1;padding:10px;margin:0 2px 2px 2px}.llms-access-plan-footer .llms-access-plan-pricing{padding:0 0 10px}.webui-popover-content .llms-members-only-restrictions{text-align:center}.webui-popover-content .llms-members-only-restrictions ul,.webui-popover-content .llms-members-only-restrictions ol,.webui-popover-content .llms-members-only-restrictions li,.webui-popover-content .llms-members-only-restrictions p{margin:0;padding:0}.webui-popover-content .llms-members-only-restrictions ul,.webui-popover-content .llms-members-only-restrictions ol,.webui-popover-content .llms-members-only-restrictions li{list-style-type:none}.webui-popover-content .llms-members-only-restrictions li{padding:8px 0;border-top:1px solid #3b3b3b}.webui-popover-content .llms-members-only-restrictions li:first-child{border-top:none}.webui-popover-content .llms-members-only-restrictions li a{display:block}.llms-checkout-wrapper form.llms-login{border:3px solid #2295ff;display:none;margin-bottom:10px}.llms-checkout-wrapper .llms-form-heading{background:#2295ff;color:#fff;margin:0 0 5px;padding:10px}.llms-checkout{background:#fff;position:relative}@media all and (min-width: 800px){.llms-checkout-cols-2 .llms-checkout-col{float:left}.llms-checkout-cols-2 .llms-checkout-col.llms-col-1{margin-right:5px;width:calc(58% - 5px)}.llms-checkout-cols-2 .llms-checkout-col.llms-col-2{margin-left:5px;width:calc(42% - 5px)}.llms-checkout-cols-2 .llms-checkout-col.llms-col-2 button{width:100%}}.llms-checkout-section{border:3px solid #2295ff;margin-bottom:10px;position:relative}.llms-checkout-section-content{margin:10px}.llms-checkout-section-content.llms-form-fields{margin:0px}.llms-checkout-section-content .llms-label{font-weight:400;font-variant:small-caps;text-transform:lowercase}.llms-checkout-section-content .llms-order-summary{list-style-type:none;margin:0;padding:0}.llms-checkout-section-content .llms-order-summary li{list-style-type:none}.llms-checkout-section-content .llms-order-summary li.llms-pricing.on-sale .price-regular,.llms-checkout-section-content .llms-order-summary li.llms-pricing.has-coupon .price-regular{text-decoration:line-through}.llms-checkout-section-content .llms-coupon-wrapper{border-top:1px solid #dadada;margin-top:10px;padding-top:10px}.llms-checkout-section-content .llms-coupon-wrapper .llms-coupon-entry{display:none;margin-top:10px}.llms-form-field.llms-payment-gateway-option label+span.llms-description{display:inline-block;margin-left:5px}.llms-form-field.llms-payment-gateway-option .llms-description a{border:none;-webkit-box-shadow:none;box-shadow:none;text-decoration:none}.llms-form-field.llms-payment-gateway-option .llms-description img{display:inline;max-height:22px;vertical-align:middle}.llms-checkout-wrapper ul.llms-payment-gateways{margin:5px 0 0;padding:0}ul.llms-payment-gateways{list-style-type:none}ul.llms-payment-gateways li:last-child:after{border-bottom:1px solid #dadada;content:"";display:block;margin:10px}ul.llms-payment-gateways .llms-payment-gateway{margin-bottom:5px;list-style-type:none}ul.llms-payment-gateways .llms-payment-gateway:last-child{margin-bottom:none}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-payment-gateway-option label{font-weight:700}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-gateway-fields{display:block}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-gateway-fields .llms-notice{margin-left:10px;margin-right:10px}ul.llms-payment-gateways .llms-payment-gateway .llms-form-field{padding-bottom:0}ul.llms-payment-gateways .llms-gateway-description{margin-left:40px}ul.llms-payment-gateways .llms-gateway-fields{display:none;margin:5px 0 20px}ul.llms-payment-gateways .llms-payment-gateway-error{padding:0 10px}.llms-checkout-confirm{margin:0 10px}.llms-payment-method{margin:10px 10px 0}.llms-gateway-description p{font-size:85%;font-style:italic;margin-bottom:0}.llms-form-fields{-webkit-box-sizing:border-box;box-sizing:border-box}.llms-form-fields *{-webkit-box-sizing:border-box;box-sizing:border-box}.llms-form-fields.flush .llms-form-field{padding:0 0 10px}.llms-form-fields .wp-block-columns,.llms-form-fields .wp-block-column{margin-bottom:0}.llms-form-heading{padding:0 10px 10px}.llms-form-field{float:left;padding:0 10px 10px;position:relative;width:100%}.llms-form-field label:empty:after{content:" "}.llms-form-field.valid input[type=date],.llms-form-field.valid input[type=time],.llms-form-field.valid input[type=datetime-local],.llms-form-field.valid input[type=week],.llms-form-field.valid input[type=month],.llms-form-field.valid input[type=text],.llms-form-field.valid input[type=email],.llms-form-field.valid input[type=url],.llms-form-field.valid input[type=password],.llms-form-field.valid input[type=search],.llms-form-field.valid input[type=tel],.llms-form-field.valid input[type=number],.llms-form-field.valid textarea,.llms-form-field.valid select{background:rgba(131,195,115,.3);border-color:#83c373}.llms-form-field.error input[type=date],.llms-form-field.error input[type=time],.llms-form-field.error input[type=datetime-local],.llms-form-field.error input[type=week],.llms-form-field.error input[type=month],.llms-form-field.error input[type=text],.llms-form-field.error input[type=email],.llms-form-field.error input[type=url],.llms-form-field.error input[type=password],.llms-form-field.error input[type=search],.llms-form-field.error input[type=tel],.llms-form-field.error input[type=number],.llms-form-field.error textarea,.llms-form-field.error select,.llms-form-field.invalid input[type=date],.llms-form-field.invalid input[type=time],.llms-form-field.invalid input[type=datetime-local],.llms-form-field.invalid input[type=week],.llms-form-field.invalid input[type=month],.llms-form-field.invalid input[type=text],.llms-form-field.invalid input[type=email],.llms-form-field.invalid input[type=url],.llms-form-field.invalid input[type=password],.llms-form-field.invalid input[type=search],.llms-form-field.invalid input[type=tel],.llms-form-field.invalid input[type=number],.llms-form-field.invalid textarea,.llms-form-field.invalid select{background:rgba(229,85,78,.3);border-color:#e5554e}.llms-form-field.llms-visually-hidden-field{display:none}.llms-form-field.align-right{text-align:right}@media screen and (min-width: 600px){.llms-form-field.llms-cols-1{width:8.3333333333%}.llms-form-field.llms-cols-2{width:16.6666666667%}.llms-form-field.llms-cols-3{width:25%}.llms-form-field.llms-cols-4{width:33.3333333333%}.llms-form-field.llms-cols-5{width:41.6666666667%}.llms-form-field.llms-cols-6{width:50%}.llms-form-field.llms-cols-7{width:58.3333333333%}.llms-form-field.llms-cols-8{width:66.6666666667%}.llms-form-field.llms-cols-9{width:75%}.llms-form-field.llms-cols-10{width:83.3333333333%}.llms-form-field.llms-cols-11{width:91.6666666667%}.llms-form-field.llms-cols-12{width:100%}}.llms-form-field.type-hidden{padding:0}.llms-form-field.type-radio input,.llms-form-field.type-radio label,.llms-form-field.type-checkbox input,.llms-form-field.type-checkbox label{display:inline-block;width:auto}.llms-form-field.type-radio input,.llms-form-field.type-checkbox input{margin-right:5px}.llms-form-field.type-radio label+.llms-description,.llms-form-field.type-checkbox label+.llms-description{display:block}.llms-form-field.type-radio:not(.is-group) input[type=radio]{position:absolute;opacity:0;visibility:none}.llms-form-field.type-radio:not(.is-group) label:before{background:#fafafa;background-position:-24px 0;background-repeat:no-repeat;border-radius:50%;-webkit-box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.35) 0 0 0 1px;box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.35) 0 0 0 1px;content:"";cursor:pointer;display:inline-block;height:22px;margin-right:5px;position:relative;-webkit-transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);top:-3px;vertical-align:middle;width:22px;z-index:2}.llms-form-field.type-radio:not(.is-group) input[type=radio]:checked+label:before{-webkit-transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);background-position:0 0;background-image:radial-gradient(ellipse at center, #2295ff 0%, #2295ff 40%, #fafafa 45%)}.llms-form-field .llms-input-group{margin-top:5px}.llms-form-field .llms-input-group .llms-form-field{padding:0 0 5px 5px}.llms-form-field.type-reset button:not(.auto),.llms-form-field.type-button button:not(.auto),.llms-form-field.type-submit button:not(.auto){width:100%}.llms-form-field .llms-description{font-size:14px;font-style:italic}.llms-form-field .llms-required{color:#e5554e;margin-left:4px}.llms-form-field input,.llms-form-field textarea,.llms-form-field select{width:100%;margin-bottom:5px}.llms-form-field .select2-container .select2-selection--single{height:auto;padding:4px 6px}.llms-form-field .select2-container--default .select2-selection--single .select2-selection__arrow{height:100%}.llms-password-strength-meter{border:1px solid #dadada;display:none;font-size:10px;margin-top:-10px;padding:1px;position:relative;text-align:center}.llms-password-strength-meter:before{bottom:0;content:"";left:0;position:absolute;top:0;-webkit-transition:width .4s ease;transition:width .4s ease}.llms-password-strength-meter.mismatch,.llms-password-strength-meter.too-short,.llms-password-strength-meter.very-weak{border-color:#e35b5b}.llms-password-strength-meter.mismatch:before,.llms-password-strength-meter.too-short:before,.llms-password-strength-meter.very-weak:before{background:rgba(227,91,91,.25);width:25%}.llms-password-strength-meter.too-short:before{width:0}.llms-password-strength-meter.weak{border-color:#f78b53}.llms-password-strength-meter.weak:before{background:rgba(247,139,83,.25);width:50%}.llms-password-strength-meter.medium{border-color:#ffc733}.llms-password-strength-meter.medium:before{background:rgba(255,199,51,.25);width:75%}.llms-password-strength-meter.strong{border-color:#83c373}.llms-password-strength-meter.strong:before{background:rgba(131,195,115,.25);width:100%}.llms-widget-syllabus--collapsible .llms-section .section-header{cursor:pointer}.llms-widget-syllabus--collapsible .llms-section.llms-section--opened .llms-collapse-caret .fa-caret-right{display:none}.llms-widget-syllabus--collapsible .llms-section.llms-section--closed .llms-collapse-caret .fa-caret-down{display:none}.llms-widget-syllabus--collapsible .llms-section.llms-section--closed .llms-lesson{display:none}.llms-widget-syllabus--collapsible .llms-syllabus-footer{text-align:left}.llms-student-dashboard .llms-sd-title{margin:25px 0}.llms-student-dashboard .llms-sd-items{list-style-type:none;margin:0;padding:0}.llms-student-dashboard .llms-sd-item{float:left;list-style-type:none;margin:0;padding:0}.llms-student-dashboard .llms-sd-item:last-child .llms-sep{display:none}.llms-student-dashboard .llms-sd-item .llms-sep{color:#333;margin:0 5px}.llms-student-dashboard .llms-sd-section{margin-bottom:25px}.llms-student-dashboard .llms-sd-section .llms-sd-section-footer{margin-top:10px}.llms-student-dashboard .orders-table{border:1px solid #f5f5f5;width:100%}.llms-student-dashboard .orders-table thead{display:none}.llms-student-dashboard .orders-table thead th,.llms-student-dashboard .orders-table thead td{font-weight:700}@media all and (min-width: 600px){.llms-student-dashboard .orders-table thead{display:table-header-group}}.llms-student-dashboard .orders-table tbody tr:nth-child(even) td,.llms-student-dashboard .orders-table tbody tr:nth-child(even) th{background:#f9f9f9}.llms-student-dashboard .orders-table tfoot th,.llms-student-dashboard .orders-table tfoot td{padding:10px;text-align:right}.llms-student-dashboard .orders-table tfoot th:last-child,.llms-student-dashboard .orders-table tfoot td:last-child{border-bottom-width:0}.llms-student-dashboard .orders-table th{font-weight:700}.llms-student-dashboard .orders-table th,.llms-student-dashboard .orders-table td{border-color:#efefef;border-style:solid;border-width:0;display:block;padding:8px 12px;text-align:center}.llms-student-dashboard .orders-table th .llms-button-primary,.llms-student-dashboard .orders-table td .llms-button-primary{display:inline-block}.llms-student-dashboard .orders-table th:last-child,.llms-student-dashboard .orders-table td:last-child{border-bottom-width:1px}.llms-student-dashboard .orders-table th:before,.llms-student-dashboard .orders-table td:before{content:attr(data-label)}@media all and (min-width: 600px){.llms-student-dashboard .orders-table th,.llms-student-dashboard .orders-table td{border-bottom-width:1px;display:table-cell;text-align:left}.llms-student-dashboard .orders-table th:first-child,.llms-student-dashboard .orders-table td:first-child{width:220px}.llms-student-dashboard .orders-table th:before,.llms-student-dashboard .orders-table td:before{display:none}}@media all and (min-width: 600px){.llms-student-dashboard .orders-table.transactions th:first-child{width:auto}}.llms-student-dashboard .llms-status{border-radius:3px;border-bottom:1px solid #fff;display:inline-block;font-size:80%;padding:3px 6px;vertical-align:middle}.llms-student-dashboard .llms-status.llms-size--large{font-size:105%;padding:6px 12px}.llms-student-dashboard .llms-status.llms-active,.llms-student-dashboard .llms-status.llms-completed,.llms-student-dashboard .llms-status.llms-pass,.llms-student-dashboard .llms-status.llms-txn-succeeded{color:#1f3818;background-color:#83c373}.llms-student-dashboard .llms-status.llms-fail,.llms-student-dashboard .llms-status.llms-failed,.llms-student-dashboard .llms-status.llms-expired,.llms-student-dashboard .llms-status.llms-cancelled,.llms-student-dashboard .llms-status.llms-txn-failed{color:#5a110d;background-color:#e5554e}.llms-student-dashboard .llms-status.llms-incomplete,.llms-student-dashboard .llms-status.llms-on-hold,.llms-student-dashboard .llms-status.llms-pending,.llms-student-dashboard .llms-status.llms-pending-cancel,.llms-student-dashboard .llms-status.llms-refunded,.llms-student-dashboard .llms-status.llms-txn-pending,.llms-student-dashboard .llms-status.llms-txn-refunded{color:#664200;background-color:orange}.llms-student-dashboard .llms-person-form-wrapper .llms-change-password{display:none}@media all and (min-width: 600px){.llms-student-dashboard .order-primary{float:left;width:68%}}@media all and (min-width: 600px){.llms-student-dashboard .order-secondary{float:left;width:32%}}.llms-student-dashboard .order-secondary form{margin-bottom:0}@media all and (min-width: 600px){.llms-student-dashboard .llms-view-order.llms-stack-cols .order-primary,.llms-student-dashboard .llms-view-order.llms-stack-cols .order-secondary{float:none;width:100%}}.llms-student-dashboard .llms-switch-payment-source .llms-notice,.llms-student-dashboard .llms-switch-payment-source .entry-content .llms-notice{margin-left:10px;margin-right:10px}.llms-student-dashboard .llms-switch-payment-source-main{border:none;display:none;margin:0}.llms-student-dashboard .llms-switch-payment-source-main ul.llms-payment-gateways{padding:10px 15px 0;margin:0}.llms-student-dashboard .llms-switch-payment-source-main .llms-payment-method,.llms-student-dashboard .llms-switch-payment-source-main ul.llms-order-summary{padding:0 25px 10px;margin:0;list-style-type:none}.llms-student-dashboard .llms-switch-payment-source-main .llms-payment-method li,.llms-student-dashboard .llms-switch-payment-source-main ul.llms-order-summary li{list-style-type:none}.llms-student-dashboard .llms-loop-list{margin:0 -10px}.llms-sd-grades .llms-table .llms-progress{display:block;margin:0}.llms-sd-grades .llms-table .llms-progress .llms-progress-bar{top:0;height:1.4em}.llms-sd-grades .llms-table .llms-progress .progress__indicator{font-size:1em;position:relative;right:.4em;top:.2em;z-index:1}.llms-table.llms-single-course-grades tbody tr:first-child td,.llms-table.llms-single-course-grades tbody tr:first-child th{background-color:#eaeaea}.llms-table.llms-single-course-grades th{font-weight:400}.llms-table.llms-single-course-grades td .llms-donut{display:inline-block;vertical-align:middle}.llms-table.llms-single-course-grades td .llms-status{margin-right:4px}.llms-table.llms-single-course-grades td .llms-donut+.llms-status{margin-left:4px}.llms-table.llms-single-course-grades th.llms-section_title{font-size:110%;font-weight:700}.llms-table.llms-single-course-grades td.llms-lesson_title{padding-left:36px;max-width:40%}.llms-table.llms-single-course-grades td.llms-associated_quiz .llms-donut{display:inline-block;margin-right:5px;vertical-align:middle}.llms-table.llms-single-course-grades td.llms-lesson_title a[href="#"]{pointer-events:none}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"]{color:inherit;position:relative}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"] .llms-tooltip{max-width:380px;width:380px}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"] .llms-tooltip.show{top:-54px}.llms-sd-widgets{display:-webkit-box;display:-ms-flexbox;display:flex}.llms-sd-widgets .llms-sd-widget{background:#f9f9f9;-webkit-box-flex:1;-ms-flex:1;flex:1;margin:10px 10px 20px;padding:0 0 20px}.llms-sd-widgets .llms-sd-widget:first-child{margin-left:0}.llms-sd-widgets .llms-sd-widget:last-child{margin-right:0}.llms-sd-widgets .llms-sd-widget .llms-sd-widget-title{background:#2295ff;color:#fff;font-size:18px;line-height:1;margin:0 0 20px;padding:10px}.llms-sd-widgets .llms-sd-widget .llms-sd-widget-empty{font-size:14px;font-style:italic;opacity:.5;text-align:center}.llms-sd-widgets .llms-sd-widget .llms-donut{margin:0 auto}.llms-sd-widgets .llms-sd-widget .llms-sd-date{opacity:.8;text-align:center;font-size:22px;line-height:1.1}.llms-sd-widgets .llms-sd-widget .llms-sd-date span{display:block}.llms-sd-widgets .llms-sd-widget .llms-sd-date span.day{font-size:52px}.llms-sd-widgets .llms-sd-widget .llms-sd-date span.diff{font-size:12px;font-style:italic;margin-top:8px;opacity:.75}.llms-sd-widgets .llms-sd-widget .llms-achievement{background:rgba(0,0,0,0);margin:0 auto;max-width:120px}.llms-sd-widgets .llms-sd-widget .llms-achievement .llms-achievement-title{display:none}.llms-sd-pagination{margin-top:24px}.llms-sd-pagination:before,.llms-sd-pagination:after{content:" ";display:table}.llms-sd-pagination:after{clear:both}.llms-sd-pagination .llms-button-secondary{display:inline-block}.llms-sd-pagination .llms-button-secondary.prev{float:left}.llms-sd-pagination .llms-button-secondary.next{float:right}.llms-sd-notification-center .llms-notification{z-index:1}.llms-table{border:1px solid #efefef;width:100%}.llms-table thead th,.llms-table thead td{font-weight:700}.llms-table tbody tr:nth-child(odd) td,.llms-table tbody tr:nth-child(odd) th{background:#f9f9f9}.llms-table tbody tr:last-child{border-bottom-width:0}.llms-table tfoot tr{background:#f9f9f9}.llms-table tfoot tr .llms-pagination .page-numbers{margin:0}.llms-table tfoot tr .llms-table-sort{text-align:right}.llms-table tfoot tr .llms-table-sort form,.llms-table tfoot tr .llms-table-sort select,.llms-table tfoot tr .llms-table-sort input,.llms-table tfoot tr .llms-table-sort button{margin:0}.llms-table th{font-weight:700}.llms-table th,.llms-table td{border-bottom:1px solid #efefef;padding:8px 12px}.llms-table th:first-child,.llms-table td:first-child{padding-left:12px}.llms-table th:last-child,.llms-table td:last-child{padding-right:12px}#page .llms-table tfoot label{display:inline}#page .llms-table tfoot select{height:auto}/*! +.llms-pagination ul:before,.llms-pagination ul:after,.llms-student-dashboard .llms-sd-items:before,.llms-form-fields:before,.llms-checkout-cols-2:before,.llms-access-plans:before,.llms-course-navigation:before,.llms-loop-list:before,.llms-cols:before,.llms-student-dashboard .llms-sd-items:after,.llms-form-fields:after,.llms-checkout-cols-2:after,.llms-access-plans:after,.llms-course-navigation:after,.llms-loop-list:after,.llms-cols:after{content:" ";display:table}.llms-pagination ul:after,.llms-student-dashboard .llms-sd-items:after,.llms-form-fields:after,.llms-checkout-cols-2:after,.llms-access-plans:after,.llms-course-navigation:after,.llms-loop-list:after,.llms-cols:after{clear:both}.llms-cols .llms-col{width:100%}@media all and (min-width: 600px){.llms-cols [class*=llms-col-]{float:left}}.llms-flex-cols{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-flow:row wrap;flex-flow:row wrap}.llms-flex-cols [class*=llms-col]{-webkit-box-flex:0;-ms-flex:0 1 auto;flex:0 1 auto;width:100%}@media all and (min-width: 600px){.llms-cols .llms-col-1,.llms-flex-cols .llms-col-1{width:100%}.llms-cols .llms-col-2,.llms-flex-cols .llms-col-2{width:50%}.llms-cols .llms-col-3,.llms-flex-cols .llms-col-3{width:33.3333333333%}.llms-cols .llms-col-4,.llms-flex-cols .llms-col-4{width:25%}.llms-cols .llms-col-5,.llms-flex-cols .llms-col-5{width:20%}.llms-cols .llms-col-6,.llms-flex-cols .llms-col-6{width:16.6666666667%}.llms-cols .llms-col-7,.llms-flex-cols .llms-col-7{width:14.2857142857%}.llms-cols .llms-col-8,.llms-flex-cols .llms-col-8{width:12.5%}.llms-cols .llms-col-9,.llms-flex-cols .llms-col-9{width:11.1111111111%}.llms-cols .llms-col-10,.llms-flex-cols .llms-col-10{width:10%}.llms-cols .llms-col-11,.llms-flex-cols .llms-col-11{width:9.0909090909%}.llms-cols .llms-col-12,.llms-flex-cols .llms-col-12{width:8.3333333333%}}.llms-button-action,.llms-button-danger,.llms-button-primary,.llms-button-secondary{border:none;border-radius:8px;color:#fefefe;cursor:pointer;font-size:16px;font-weight:700;text-decoration:none;text-shadow:none;line-height:1;margin:0;max-width:100%;padding:12px 24px;position:relative;-webkit-transition:all .5s ease;transition:all .5s ease}.llms-button-action:disabled,.llms-button-danger:disabled,.llms-button-primary:disabled,.llms-button-secondary:disabled{opacity:.5}.llms-button-action:hover,.llms-button-action:active,.llms-button-danger:hover,.llms-button-danger:active,.llms-button-primary:hover,.llms-button-primary:active,.llms-button-secondary:hover,.llms-button-secondary:active{color:#fefefe}.llms-button-action:focus,.llms-button-danger:focus,.llms-button-primary:focus,.llms-button-secondary:focus{color:#fefefe}.llms-button-action.auto,.llms-button-danger.auto,.llms-button-primary.auto,.llms-button-secondary.auto{width:auto}.llms-button-action.full,.llms-button-danger.full,.llms-button-primary.full,.llms-button-secondary.full{display:block;text-align:center;width:100%}.llms-button-action.square,.llms-button-danger.square,.llms-button-primary.square,.llms-button-secondary.square{padding:12px}.llms-button-action.small,.llms-button-danger.small,.llms-button-primary.small,.llms-button-secondary.small{font-size:13px;padding:8px 14px}.llms-button-action.small.square,.llms-button-danger.small.square,.llms-button-primary.small.square,.llms-button-secondary.small.square{padding:8px}.llms-button-action.large,.llms-button-danger.large,.llms-button-primary.large,.llms-button-secondary.large{font-size:18px;line-height:1.2;padding:16px 32px}.llms-button-action.large.square,.llms-button-danger.large.square,.llms-button-primary.large.square,.llms-button-secondary.large.square{padding:16px}.llms-button-action.large .fa,.llms-button-danger.large .fa,.llms-button-primary.large .fa,.llms-button-secondary.large .fa{left:-7px;position:relative}.llms-button-primary{background:#2295ff}.llms-button-primary:hover,.llms-button-primary.clicked{background:#0077e4}.llms-button-primary:focus,.llms-button-primary:active{background:#4ba9ff}.llms-button-secondary{background:#e1e1e1;color:#414141}.llms-button-secondary:hover{color:#414141;background:#cdcdcd}.llms-button-secondary:focus,.llms-button-secondary:active{color:#414141;background:#ebebeb}.llms-button-action{background:#f8954f}.llms-button-action:hover,.llms-button-action.clicked{background:#f67d28}.llms-button-action:focus,.llms-button-action:active{background:#faad76}.llms-button-danger{background:#e5554e}.llms-button-danger:hover{background:#e0332a}.llms-button-danger:focus,.llms-button-danger:active{background:#e86660}.llms-button-outline{background:rgba(0,0,0,0);border:3px solid #1d2327;border-radius:8px;color:#1d2327;cursor:pointer;font-size:16px;font-weight:700;text-decoration:none;text-shadow:none;line-height:1;margin:0;max-width:100%;padding:12px 24px;position:relative;-webkit-transition:all .5s ease;transition:all .5s ease}.llms-button-outline:disabled{opacity:.5}.llms-button-outline:hover,.llms-button-outline:active{color:#1d2327}.llms-button-outline:focus{color:#1d2327}.llms-button-outline.auto{width:auto}.llms-button-outline.full{display:block;text-align:center;width:100%}.llms-button-outline.square{padding:12px}.llms-donut{background-color:#f1f1f1;background-image:none;border-radius:50%;color:#ef476f;height:200px;overflow:hidden;position:relative;width:200px}.llms-donut:before,.llms-donut:after{content:" ";display:table}.llms-donut:after{clear:both}.llms-donut svg{overflow:visible !important;pointer-events:none;width:100%}.llms-donut svg path{fill:none;stroke-width:35px;stroke:#ef476f}.llms-donut.mini{height:36px;width:36px}.llms-donut.mini .percentage{font-size:10px}.llms-donut.small{height:100px;width:100px}.llms-donut.small .percentage{font-size:18px}.llms-donut.medium{height:130px;width:130px}.llms-donut.medium .percentage{font-size:26px}.llms-donut.large{height:260px;width:260px}.llms-donut.large .percentage{font-size:48px}.llms-donut .inside{-webkit-box-align:center;-ms-flex-align:center;align-items:center;background:#fff;border-radius:50%;-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;height:80%;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;left:50%;position:absolute;text-align:center;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%);width:80%;top:50%;z-index:3}.llms-donut .percentage{line-height:1.2;font-size:34px}.llms-donut .caption{font-size:50%}.lifterlms [data-tip],.lifterlms [data-title-default],.lifterlms [data-title-active],.llms-metabox [data-tip],.llms-metabox [data-title-default],.llms-metabox [data-title-active],.llms-mb-container [data-tip],.llms-mb-container [data-title-default],.llms-mb-container [data-title-active],.llms-quiz-wrapper [data-tip],.llms-quiz-wrapper [data-title-default],.llms-quiz-wrapper [data-title-active]{position:relative}.lifterlms [data-tip].tip--top-right:before,.lifterlms [data-title-default].tip--top-right:before,.lifterlms [data-title-active].tip--top-right:before,.llms-metabox [data-tip].tip--top-right:before,.llms-metabox [data-title-default].tip--top-right:before,.llms-metabox [data-title-active].tip--top-right:before,.llms-mb-container [data-tip].tip--top-right:before,.llms-mb-container [data-title-default].tip--top-right:before,.llms-mb-container [data-title-active].tip--top-right:before,.llms-quiz-wrapper [data-tip].tip--top-right:before,.llms-quiz-wrapper [data-title-default].tip--top-right:before,.llms-quiz-wrapper [data-title-active].tip--top-right:before{bottom:100%;left:-10px}.lifterlms [data-tip].tip--top-right:hover:before,.lifterlms [data-title-default].tip--top-right:hover:before,.lifterlms [data-title-active].tip--top-right:hover:before,.llms-metabox [data-tip].tip--top-right:hover:before,.llms-metabox [data-title-default].tip--top-right:hover:before,.llms-metabox [data-title-active].tip--top-right:hover:before,.llms-mb-container [data-tip].tip--top-right:hover:before,.llms-mb-container [data-title-default].tip--top-right:hover:before,.llms-mb-container [data-title-active].tip--top-right:hover:before,.llms-quiz-wrapper [data-tip].tip--top-right:hover:before,.llms-quiz-wrapper [data-title-default].tip--top-right:hover:before,.llms-quiz-wrapper [data-title-active].tip--top-right:hover:before{bottom:calc(100% + 6px)}.lifterlms [data-tip].tip--top-right:after,.lifterlms [data-title-default].tip--top-right:after,.lifterlms [data-title-active].tip--top-right:after,.llms-metabox [data-tip].tip--top-right:after,.llms-metabox [data-title-default].tip--top-right:after,.llms-metabox [data-title-active].tip--top-right:after,.llms-mb-container [data-tip].tip--top-right:after,.llms-mb-container [data-title-default].tip--top-right:after,.llms-mb-container [data-title-active].tip--top-right:after,.llms-quiz-wrapper [data-tip].tip--top-right:after,.llms-quiz-wrapper [data-title-default].tip--top-right:after,.llms-quiz-wrapper [data-title-active].tip--top-right:after{border-top-color:#444;left:6px;top:0}.lifterlms [data-tip].tip--top-right:hover:after,.lifterlms [data-title-default].tip--top-right:hover:after,.lifterlms [data-title-active].tip--top-right:hover:after,.llms-metabox [data-tip].tip--top-right:hover:after,.llms-metabox [data-title-default].tip--top-right:hover:after,.llms-metabox [data-title-active].tip--top-right:hover:after,.llms-mb-container [data-tip].tip--top-right:hover:after,.llms-mb-container [data-title-default].tip--top-right:hover:after,.llms-mb-container [data-title-active].tip--top-right:hover:after,.llms-quiz-wrapper [data-tip].tip--top-right:hover:after,.llms-quiz-wrapper [data-title-default].tip--top-right:hover:after,.llms-quiz-wrapper [data-title-active].tip--top-right:hover:after{top:-6px}.lifterlms [data-tip].tip--top-left:before,.lifterlms [data-title-default].tip--top-left:before,.lifterlms [data-title-active].tip--top-left:before,.llms-metabox [data-tip].tip--top-left:before,.llms-metabox [data-title-default].tip--top-left:before,.llms-metabox [data-title-active].tip--top-left:before,.llms-mb-container [data-tip].tip--top-left:before,.llms-mb-container [data-title-default].tip--top-left:before,.llms-mb-container [data-title-active].tip--top-left:before,.llms-quiz-wrapper [data-tip].tip--top-left:before,.llms-quiz-wrapper [data-title-default].tip--top-left:before,.llms-quiz-wrapper [data-title-active].tip--top-left:before{bottom:100%;right:-10px}.lifterlms [data-tip].tip--top-left:hover:before,.lifterlms [data-title-default].tip--top-left:hover:before,.lifterlms [data-title-active].tip--top-left:hover:before,.llms-metabox [data-tip].tip--top-left:hover:before,.llms-metabox [data-title-default].tip--top-left:hover:before,.llms-metabox [data-title-active].tip--top-left:hover:before,.llms-mb-container [data-tip].tip--top-left:hover:before,.llms-mb-container [data-title-default].tip--top-left:hover:before,.llms-mb-container [data-title-active].tip--top-left:hover:before,.llms-quiz-wrapper [data-tip].tip--top-left:hover:before,.llms-quiz-wrapper [data-title-default].tip--top-left:hover:before,.llms-quiz-wrapper [data-title-active].tip--top-left:hover:before{bottom:calc(100% + 6px)}.lifterlms [data-tip].tip--top-left:after,.lifterlms [data-title-default].tip--top-left:after,.lifterlms [data-title-active].tip--top-left:after,.llms-metabox [data-tip].tip--top-left:after,.llms-metabox [data-title-default].tip--top-left:after,.llms-metabox [data-title-active].tip--top-left:after,.llms-mb-container [data-tip].tip--top-left:after,.llms-mb-container [data-title-default].tip--top-left:after,.llms-mb-container [data-title-active].tip--top-left:after,.llms-quiz-wrapper [data-tip].tip--top-left:after,.llms-quiz-wrapper [data-title-default].tip--top-left:after,.llms-quiz-wrapper [data-title-active].tip--top-left:after{border-top-color:#444;right:6px;top:0}.lifterlms [data-tip].tip--top-left:hover:after,.lifterlms [data-title-default].tip--top-left:hover:after,.lifterlms [data-title-active].tip--top-left:hover:after,.llms-metabox [data-tip].tip--top-left:hover:after,.llms-metabox [data-title-default].tip--top-left:hover:after,.llms-metabox [data-title-active].tip--top-left:hover:after,.llms-mb-container [data-tip].tip--top-left:hover:after,.llms-mb-container [data-title-default].tip--top-left:hover:after,.llms-mb-container [data-title-active].tip--top-left:hover:after,.llms-quiz-wrapper [data-tip].tip--top-left:hover:after,.llms-quiz-wrapper [data-title-default].tip--top-left:hover:after,.llms-quiz-wrapper [data-title-active].tip--top-left:hover:after{top:-6px}.lifterlms [data-tip].tip--bottom-left:before,.lifterlms [data-title-default].tip--bottom-left:before,.lifterlms [data-title-active].tip--bottom-left:before,.llms-metabox [data-tip].tip--bottom-left:before,.llms-metabox [data-title-default].tip--bottom-left:before,.llms-metabox [data-title-active].tip--bottom-left:before,.llms-mb-container [data-tip].tip--bottom-left:before,.llms-mb-container [data-title-default].tip--bottom-left:before,.llms-mb-container [data-title-active].tip--bottom-left:before,.llms-quiz-wrapper [data-tip].tip--bottom-left:before,.llms-quiz-wrapper [data-title-default].tip--bottom-left:before,.llms-quiz-wrapper [data-title-active].tip--bottom-left:before{top:100%;right:-10px}.lifterlms [data-tip].tip--bottom-left:hover:before,.lifterlms [data-title-default].tip--bottom-left:hover:before,.lifterlms [data-title-active].tip--bottom-left:hover:before,.llms-metabox [data-tip].tip--bottom-left:hover:before,.llms-metabox [data-title-default].tip--bottom-left:hover:before,.llms-metabox [data-title-active].tip--bottom-left:hover:before,.llms-mb-container [data-tip].tip--bottom-left:hover:before,.llms-mb-container [data-title-default].tip--bottom-left:hover:before,.llms-mb-container [data-title-active].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-tip].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-title-default].tip--bottom-left:hover:before,.llms-quiz-wrapper [data-title-active].tip--bottom-left:hover:before{top:calc(100% + 6px)}.lifterlms [data-tip].tip--bottom-left:after,.lifterlms [data-title-default].tip--bottom-left:after,.lifterlms [data-title-active].tip--bottom-left:after,.llms-metabox [data-tip].tip--bottom-left:after,.llms-metabox [data-title-default].tip--bottom-left:after,.llms-metabox [data-title-active].tip--bottom-left:after,.llms-mb-container [data-tip].tip--bottom-left:after,.llms-mb-container [data-title-default].tip--bottom-left:after,.llms-mb-container [data-title-active].tip--bottom-left:after,.llms-quiz-wrapper [data-tip].tip--bottom-left:after,.llms-quiz-wrapper [data-title-default].tip--bottom-left:after,.llms-quiz-wrapper [data-title-active].tip--bottom-left:after{border-bottom-color:#444;right:6px;bottom:0}.lifterlms [data-tip].tip--bottom-left:hover:after,.lifterlms [data-title-default].tip--bottom-left:hover:after,.lifterlms [data-title-active].tip--bottom-left:hover:after,.llms-metabox [data-tip].tip--bottom-left:hover:after,.llms-metabox [data-title-default].tip--bottom-left:hover:after,.llms-metabox [data-title-active].tip--bottom-left:hover:after,.llms-mb-container [data-tip].tip--bottom-left:hover:after,.llms-mb-container [data-title-default].tip--bottom-left:hover:after,.llms-mb-container [data-title-active].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-tip].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-title-default].tip--bottom-left:hover:after,.llms-quiz-wrapper [data-title-active].tip--bottom-left:hover:after{bottom:-6px}.lifterlms [data-tip].tip--bottom-right:before,.lifterlms [data-title-default].tip--bottom-right:before,.lifterlms [data-title-active].tip--bottom-right:before,.llms-metabox [data-tip].tip--bottom-right:before,.llms-metabox [data-title-default].tip--bottom-right:before,.llms-metabox [data-title-active].tip--bottom-right:before,.llms-mb-container [data-tip].tip--bottom-right:before,.llms-mb-container [data-title-default].tip--bottom-right:before,.llms-mb-container [data-title-active].tip--bottom-right:before,.llms-quiz-wrapper [data-tip].tip--bottom-right:before,.llms-quiz-wrapper [data-title-default].tip--bottom-right:before,.llms-quiz-wrapper [data-title-active].tip--bottom-right:before{top:100%;left:-10px}.lifterlms [data-tip].tip--bottom-right:hover:before,.lifterlms [data-title-default].tip--bottom-right:hover:before,.lifterlms [data-title-active].tip--bottom-right:hover:before,.llms-metabox [data-tip].tip--bottom-right:hover:before,.llms-metabox [data-title-default].tip--bottom-right:hover:before,.llms-metabox [data-title-active].tip--bottom-right:hover:before,.llms-mb-container [data-tip].tip--bottom-right:hover:before,.llms-mb-container [data-title-default].tip--bottom-right:hover:before,.llms-mb-container [data-title-active].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-tip].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-title-default].tip--bottom-right:hover:before,.llms-quiz-wrapper [data-title-active].tip--bottom-right:hover:before{top:calc(100% + 6px)}.lifterlms [data-tip].tip--bottom-right:after,.lifterlms [data-title-default].tip--bottom-right:after,.lifterlms [data-title-active].tip--bottom-right:after,.llms-metabox [data-tip].tip--bottom-right:after,.llms-metabox [data-title-default].tip--bottom-right:after,.llms-metabox [data-title-active].tip--bottom-right:after,.llms-mb-container [data-tip].tip--bottom-right:after,.llms-mb-container [data-title-default].tip--bottom-right:after,.llms-mb-container [data-title-active].tip--bottom-right:after,.llms-quiz-wrapper [data-tip].tip--bottom-right:after,.llms-quiz-wrapper [data-title-default].tip--bottom-right:after,.llms-quiz-wrapper [data-title-active].tip--bottom-right:after{border-bottom-color:#444;left:6px;bottom:0}.lifterlms [data-tip].tip--bottom-right:hover:after,.lifterlms [data-title-default].tip--bottom-right:hover:after,.lifterlms [data-title-active].tip--bottom-right:hover:after,.llms-metabox [data-tip].tip--bottom-right:hover:after,.llms-metabox [data-title-default].tip--bottom-right:hover:after,.llms-metabox [data-title-active].tip--bottom-right:hover:after,.llms-mb-container [data-tip].tip--bottom-right:hover:after,.llms-mb-container [data-title-default].tip--bottom-right:hover:after,.llms-mb-container [data-title-active].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-tip].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-title-default].tip--bottom-right:hover:after,.llms-quiz-wrapper [data-title-active].tip--bottom-right:hover:after{bottom:-6px}.lifterlms [data-tip]:before,.lifterlms [data-title-default]:before,.lifterlms [data-title-active]:before,.llms-metabox [data-tip]:before,.llms-metabox [data-title-default]:before,.llms-metabox [data-title-active]:before,.llms-mb-container [data-tip]:before,.llms-mb-container [data-title-default]:before,.llms-mb-container [data-title-active]:before,.llms-quiz-wrapper [data-tip]:before,.llms-quiz-wrapper [data-title-default]:before,.llms-quiz-wrapper [data-title-active]:before{background:#444;border-radius:4px;color:#fff;font-size:13px;line-height:1.2;padding:8px;max-width:300px;width:-webkit-max-content;width:-moz-max-content;width:max-content}.lifterlms [data-tip]:after,.lifterlms [data-title-default]:after,.lifterlms [data-title-active]:after,.llms-metabox [data-tip]:after,.llms-metabox [data-title-default]:after,.llms-metabox [data-title-active]:after,.llms-mb-container [data-tip]:after,.llms-mb-container [data-title-default]:after,.llms-mb-container [data-title-active]:after,.llms-quiz-wrapper [data-tip]:after,.llms-quiz-wrapper [data-title-default]:after,.llms-quiz-wrapper [data-title-active]:after{content:"";border:6px solid rgba(0,0,0,0);height:0;width:0}.lifterlms [data-tip]:before,.lifterlms [data-tip]:after,.lifterlms [data-title-default]:before,.lifterlms [data-title-default]:after,.lifterlms [data-title-active]:before,.lifterlms [data-title-active]:after,.llms-metabox [data-tip]:before,.llms-metabox [data-tip]:after,.llms-metabox [data-title-default]:before,.llms-metabox [data-title-default]:after,.llms-metabox [data-title-active]:before,.llms-metabox [data-title-active]:after,.llms-mb-container [data-tip]:before,.llms-mb-container [data-tip]:after,.llms-mb-container [data-title-default]:before,.llms-mb-container [data-title-default]:after,.llms-mb-container [data-title-active]:before,.llms-mb-container [data-title-active]:after,.llms-quiz-wrapper [data-tip]:before,.llms-quiz-wrapper [data-tip]:after,.llms-quiz-wrapper [data-title-default]:before,.llms-quiz-wrapper [data-title-default]:after,.llms-quiz-wrapper [data-title-active]:before,.llms-quiz-wrapper [data-title-active]:after{opacity:0;-webkit-transition:all .2s .1s ease;transition:all .2s .1s ease;position:absolute;pointer-events:none;visibility:hidden}.lifterlms [data-tip]:hover:before,.lifterlms [data-tip]:hover:after,.lifterlms [data-title-default]:hover:before,.lifterlms [data-title-default]:hover:after,.lifterlms [data-title-active]:hover:before,.lifterlms [data-title-active]:hover:after,.llms-metabox [data-tip]:hover:before,.llms-metabox [data-tip]:hover:after,.llms-metabox [data-title-default]:hover:before,.llms-metabox [data-title-default]:hover:after,.llms-metabox [data-title-active]:hover:before,.llms-metabox [data-title-active]:hover:after,.llms-mb-container [data-tip]:hover:before,.llms-mb-container [data-tip]:hover:after,.llms-mb-container [data-title-default]:hover:before,.llms-mb-container [data-title-default]:hover:after,.llms-mb-container [data-title-active]:hover:before,.llms-mb-container [data-title-active]:hover:after,.llms-quiz-wrapper [data-tip]:hover:before,.llms-quiz-wrapper [data-tip]:hover:after,.llms-quiz-wrapper [data-title-default]:hover:before,.llms-quiz-wrapper [data-title-default]:hover:after,.llms-quiz-wrapper [data-title-active]:hover:before,.llms-quiz-wrapper [data-title-active]:hover:after{opacity:1;-webkit-transition:all .2s .6s ease;transition:all .2s .6s ease;visibility:visible;z-index:99999999}.lifterlms [data-tip]:before,.llms-metabox [data-tip]:before,.llms-mb-container [data-tip]:before,.llms-quiz-wrapper [data-tip]:before{content:attr(data-tip)}.lifterlms [data-tip].active:before,.llms-metabox [data-tip].active:before,.llms-mb-container [data-tip].active:before,.llms-quiz-wrapper [data-tip].active:before{content:attr(data-tip-active)}.llms-membership-image{display:block;margin:0 auto}.llms-course-image{display:block;margin:0 auto;max-width:100%}.llms-featured-image{display:block;margin:0 auto}.llms-image-thumb{width:150px}.llms-video-wrapper .center-video{height:auto;max-width:100%;overflow:hidden;position:relative;padding-top:56.25%;text-align:center}.llms-video-wrapper .center-video>.wp-video,.llms-video-wrapper .center-video .fluid-width-video-wrapper,.llms-video-wrapper .center-video iframe,.llms-video-wrapper .center-video object,.llms-video-wrapper .center-video embed{height:100%;left:0;position:absolute;top:0;width:100%}.llms-video-wrapper .center-video>.wp-video{width:100% !important}.llms-video-wrapper .center-video .fluid-width-video-wrapper{padding-top:0 !important}.clear{clear:both;width:100%}.llms-featured-image{text-align:center}#main-content .llms-payment-options p{margin:0;font-size:16px}.llms-option{display:block;position:relative;margin:20px 0;padding-left:40px;font-size:16px}.llms-option label{cursor:pointer;position:static}.llms-option:first-child{margin-top:0}.llms-option:last-child{margin-bottom:0}#main-content .llms-option:last-child{margin-bottom:0}.llms-option input[type=radio]{display:block;position:absolute;top:3px;left:0;z-index:0}.llms-option input[type=radio]{display:inline-block}.llms-option input[type=radio]+label span.llms-radio{display:none}.llms-option input[type=radio]+label span.llms-radio{-webkit-appearance:none;-moz-appearance:none;appearance:none;z-index:20;position:absolute;top:0;left:-2px;display:inline-block;width:24px;height:24px;border-radius:50%;cursor:pointer;vertical-align:middle;-webkit-box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.5) 0 0 0 1px;box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.5) 0 0 0 1px;background:#efefef;background-image:radial-gradient(ellipse at center, #e5554e 0%, #e5554e 40%, #efefef 45%);background-repeat:no-repeat;-webkit-transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);transition:background-position .15s cubic-bezier(0.8, 0, 1, 1)}.llms-option input[type=radio]:checked+label span.llms-radio{-webkit-transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1)}.llms-option input[type=radio]+label span.llms-radio{background-position:-24px 0}.llms-option input[type=radio]:checked+label span.llms-radio{background-position:0 0}.llms-option input[type=submit]{border:none;background:#e5554e;color:#fff;font-size:20px;padding:10px 0;border-radius:3px;cursor:pointer;width:100%}.llms-styled-text{padding:14px 0}.llms-notice-box{border-radius:3px;z-index:10;margin:10px 0;padding:15px 20px;border:1px solid #ccc;list-style-type:none;width:100%;overflow:auto}.llms-notice-box input[type=text]{height:auto}.llms-notice-box .col-1-1{width:100%}.llms-notice-box .col-1-1 input[type=text]{width:100%}.llms-notice-box .col-1-2{width:50%;float:left}@media screen and (max-width: 768px){.llms-notice-box .col-1-2{width:100%}}.llms-notice-box .col-1-3{width:33%;float:left;margin-right:10px}.llms-notice-box .col-1-4{width:25%;float:left;margin-right:10px}@media screen and (max-width: 768px){.llms-notice-box .col-1-4{width:100%}}.llms-notice-box .col-1-6{width:16.6%;float:left;margin-right:10px}.llms-notice-box .col-1-8{width:11%;float:right}.llms-notice-box .llms-pad-right{padding-right:10px}@media screen and (max-width: 768px){.llms-notice-box .llms-pad-right{padding-right:0}}input[type=text].cc_cvv,#cc_cvv{margin-right:0;width:23%;float:right}.llms-clear-box{border-radius:3px;z-index:10;margin:10px 0;padding:15px 20px;list-style-type:none;width:100%;overflow:auto}.llms-price-label{font-weight:normal}.llms-final-price{font-weight:bold;float:right}.llms-center-content{text-align:center}.llms-input-text{background-color:#fff;border:1px solid #ddd;color:#333;font-size:18px;font-weight:300;padding:16px;width:100%}.llms-price{margin-bottom:0;font-weight:bold}.llms-price-loop{margin-bottom:0;font-weight:bold}.courses .entry{padding:0}.list-view .site-content .llms-course-list .hentry,.list-view .site-content .llms-membership-list .hentry{border-top:0;padding-top:0}.llms-content{width:100%}.llms-lesson-button-wrapper{width:100%;display:block;clear:both;text-align:center}.llms-template-wrapper{width:100%;display:block;clear:both}.llms-button-wrapper{width:100%;display:block;clear:both;text-align:center}.llms-styled-select{border:1px solid #ccc;-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:3px;overflow:hidden;position:relative}.llms-styled-select,.llms-styled-select select{width:100%}select:focus{outline:none}.llms-styled-select select{height:34px;padding:5px 0 5px 5px;background:rgba(0,0,0,0);border:none;-webkit-appearance:none;font-size:16px;color:#444}@-moz-document url-prefix(){.--ms-styled-select select{width:110%}}.llms-styled-select .fa-sort-desc{position:absolute;top:0;right:12px;font-size:24px;color:#ccc}select::-ms-expand{display:none}_:-o-prefocus .llms-styled-select,.selector .llms-styled-select{background:none}.llms-form-item-wrapper{margin-bottom:1em}.llms-progress-circle{position:relative;width:200px;height:200px;float:left}.llms-progress-circle-count{top:27%;position:absolute;width:94%;text-align:center;color:#666;font-size:44px}.llms-progress-circle svg{position:absolute;width:200px;height:200px}.llms-progress-circle circle{fill:rgba(0,0,0,0)}svg .llms-background-circle{fill:rgba(0,0,0,0);stroke-width:10px;stroke:#f1f2f1;stroke-dasharray:430}svg .llms-animated-circle{fill:rgba(0,0,0,0);stroke-width:10px;stroke:#e5554e;stroke-dasharray:430;stroke-dashoffset:410}.llms-widget-syllabus .llms-lesson.current-lesson .lesson-title{font-weight:700}.llms-widget-syllabus .llms-lesson-complete,.llms-widget-syllabus .lesson-complete-placeholder{font-size:1.2em;margin-right:6px;color:#ccc}.llms-widget-syllabus .llms-lesson-complete.done,.llms-widget-syllabus .lesson-complete-placeholder.done{color:#e5554e}.llms-widget-syllabus .section-title{font-weight:bold}.llms-widget-syllabus .lesson-title a{text-decoration:none}.llms-widget-syllabus .lesson-title a:hover{text-decoration:none !important}.llms-widget-syllabus .lesson-title.done a{color:#999;text-decoration:line-through}.llms-widget-syllabus ul{list-style-type:none}.llms-widget-syllabus ul li{list-style-type:none}.llms-widget-syllabus ul li ul li{margin:0 0 2px 0;padding:0}.llms-remove-coupon{float:right}.llms-lesson-link-locked,.llms-lesson-link-locked:hover{background:#f1f1f1;-webkit-box-shadow:0 1px 2px 0 rgba(1,1,1,.4);box-shadow:0 1px 2px 0 rgba(1,1,1,.4);display:block;color:#a6a6a6;min-height:85px;padding:15px;text-decoration:none;position:relative}.llms-lesson-preview.is-complete .llms-lesson-link-locked{padding-left:75px}.llms-lesson-tooltip{display:none;position:absolute;color:#000;background-color:silver;padding:.25em;border-radius:2px;z-index:100;top:0;left:50%;text-align:center;-webkit-transform:translateX(-50%) translateY(-100%);transform:translateX(-50%) translateY(-100%)}.llms-lesson-tooltip:after{content:"";width:0;height:0;border-top:8px solid silver;border-left:8px solid rgba(0,0,0,0);border-right:8px solid rgba(0,0,0,0);position:absolute;bottom:-8px;left:50%;-webkit-transform:translateX(-50%);transform:translateX(-50%)}.llms-lesson-tooltip.active{display:inline-block}.llms-favorite-wrapper{cursor:pointer}.llms-favorite-wrapper .fa-heart{color:#ef476f}.llms-has-favorite .llms-parent-course-link{display:inline-block;margin-bottom:20px}.llms-has-favorite .llms-parent-course-link+.llms-favorite-wrapper{float:right;margin:0}.llms-syllabus-wrapper .llms-has-favorite{text-align:left}.llms-syllabus-wrapper .llms-has-favorite .llms-favorite-wrapper{display:inline-block}.llms-loop-list{list-style:none;margin:0 -10px;padding:0}@media all and (min-width: 600px){.llms-loop-list.cols-1 .llms-loop-item{width:100%}.llms-loop-list.cols-2 .llms-loop-item{width:50%}.llms-loop-list.cols-3 .llms-loop-item{width:33.3333333333%}.llms-loop-list.cols-4 .llms-loop-item{width:25%}.llms-loop-list.cols-5 .llms-loop-item{width:20%}.llms-loop-list.cols-6 .llms-loop-item{width:16.6666666667%}}.llms-loop-item{float:left;list-style:none;margin:0;padding:0;width:100%}.llms-loop-item-content{background:#f1f1f1;padding-bottom:10px;margin:10px}.llms-loop-item-content:hover{background:#eaeaea}.llms-loop-item-content .llms-loop-link{color:#212121;display:block}.llms-loop-item-content .llms-loop-link:visited{color:#212121}.llms-loop-item-content .llms-featured-image{display:block;max-width:100%}.llms-loop-item-content .llms-loop-title{margin-top:5px}.llms-loop-item-content .llms-loop-title:hover{color:#2295ff}.llms-loop-item-content .llms-meta,.llms-loop-item-content .llms-author,.llms-loop-item-content .llms-loop-title{padding:0 10px}.llms-loop-item-content .llms-meta,.llms-loop-item-content .llms-author{color:#444;display:block;font-size:13px;margin-bottom:3px}.llms-loop-item-content .llms-meta:last-child,.llms-loop-item-content .llms-author:last-child{margin-bottom:0}.llms-loop-item-content .llms-featured-img-wrap{overflow:hidden}.llms-loop-item-content p{margin-bottom:0}.llms-loop-item-content .llms-progress{margin:0;height:.4em}.llms-loop-item-content .llms-progress .progress__indicator{display:none}.llms-loop-item-content .llms-progress .llms-progress-bar{background-color:#f6f6f6;right:0;top:0}.course .llms-meta-info{margin:20px 0}.course .llms-meta-info .llms-meta-title{margin-bottom:5px}.course .llms-meta-info .llms-meta p{margin-bottom:0}.course .llms-meta-info .llms-meta span{font-weight:700}.course .llms-course-progress{margin:40px auto;max-width:480px;text-align:center}.llms-syllabus-wrapper{margin:15px;text-align:center}.llms-syllabus-wrapper .llms-section-title{margin:25px 0 0}.llms-course-navigation .llms-prev-lesson,.llms-course-navigation .llms-next-lesson,.llms-course-navigation .llms-back-to-course{width:49%}.llms-course-navigation .llms-prev-lesson,.llms-course-navigation .llms-back-to-course{float:left;margin-right:.5%}.llms-course-navigation .llms-next-lesson,.llms-course-navigation .llms-prev-lesson+.llms-back-to-course{float:right;margin-left:.5%}.llms-lesson-preview{display:inline-block;margin-top:15px;max-width:100%;position:relative;width:480px}.llms-lesson-preview .llms-lesson-link{background:#f1f1f1;color:#212121;display:block;padding:15px;text-decoration:none}.llms-lesson-preview .llms-lesson-link:before,.llms-lesson-preview .llms-lesson-link:after{content:" ";display:table}.llms-lesson-preview .llms-lesson-link:after{clear:both}.llms-lesson-preview .llms-lesson-link:hover{background:#eaeaea}.llms-lesson-preview .llms-lesson-link:visited{color:#212121}.llms-lesson-preview .llms-lesson-thumbnail{margin-bottom:10px}.llms-lesson-preview .llms-lesson-thumbnail img{display:block;width:100%}.llms-lesson-preview .llms-pre-text{text-align:left}.llms-lesson-preview .llms-lesson-title{font-weight:700;margin:0 auto 10px;text-align:left}.llms-lesson-preview .llms-lesson-title:last-child{margin-bottom:0}.llms-lesson-preview .llms-lesson-excerpt{text-align:left}.llms-lesson-preview .llms-main{float:left;width:100%}.llms-lesson-preview .llms-extra{float:right;width:15%}.llms-lesson-preview .llms-extra+.llms-main{width:85%}.llms-lesson-preview .llms-lesson-counter,.llms-lesson-preview .llms-free-lesson-svg,.llms-lesson-preview .llms-lesson-complete,.llms-lesson-preview .llms-lesson-complete-placeholder{display:block;font-size:32px;margin-bottom:15px}.llms-lesson-preview.is-free .llms-lesson-complete,.llms-lesson-preview.is-complete .llms-lesson-complete{color:#2295ff}.llms-lesson-preview .llms-icon-free{background:#2295ff;border-radius:4px;color:#f1f1f1;display:inline-block;padding:5px 6px 4px;line-height:1;font-size:14px}.llms-lesson-preview.is-incomplete .llms-lesson-complete{color:#cacaca}.llms-lesson-preview .llms-lesson-counter{font-size:16px;line-height:1}.llms-lesson-preview .llms-free-lesson-svg{fill:currentColor;height:23px;width:50px}.llms-lesson-preview p{margin-bottom:0}.llms-progress{clear:both;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:reverse;-ms-flex-direction:row-reverse;flex-direction:row-reverse;position:relative;height:1em;width:100%;margin:15px 0}.llms-progress .llms-progress-bar{background-color:#f1f2f1;position:relative;height:.4em;top:.3em;width:100%}.llms-progress .progress-bar-complete{background-color:#ef476f;height:100%}.progress__indicator{float:right;text-align:right;height:1em;line-height:1em;margin-left:5px;white-space:nowrap}.llms-author .name{margin-left:5px}.llms-author .label{margin-left:5px}.llms-author .avatar{border-radius:50%}.llms-author .bio{margin-top:5px}.llms-instructor-info .llms-instructors .llms-col:first-child .llms-author{margin-left:0}.llms-instructor-info .llms-instructors .llms-col:last-child .llms-author{margin-right:0}.llms-instructor-info .llms-instructors .llms-author{background:#f5f5f5;border-top:4px solid #2295ff;text-align:center;margin:45px 5px 5px;padding:0 10px 10px}.llms-instructor-info .llms-instructors .llms-author .avatar{background:#2295ff;border:4px solid #2295ff;display:block;margin:-35px auto 10px}.llms-instructor-info .llms-instructors .llms-author .llms-author-info{display:block}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.name{font-weight:700}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.label{font-size:85%}.llms-instructor-info .llms-instructors .llms-author .llms-author-info.bio{font-size:90%;margin-bottom:0}.llms_review{margin:20px 0px;padding:10px}.llms_review h5{font-size:17px;margin:3px 0px}.llms_review h6{font-size:13px}.llms_review p{font-size:15px}.review_box [type=text]{margin:10px 0px}.review_box h5{color:red;display:none}.review_box+.thank_you_box{display:none}.llms-notice{background:rgba(34,149,255,.3);border-color:#2295ff;border-style:solid;border-width:3px;padding:10px;margin-bottom:10px}.llms-notice p:last-child,.llms-notice ul:last-child{margin-bottom:0}.llms-notice li{list-style-type:none}.llms-notice.llms-debug{background:rgba(202,202,202,.3);border-color:#cacaca}.llms-notice.llms-error{background:rgba(229,85,78,.3);border-color:#e5554e}.llms-notice.llms-success{background:rgba(131,195,115,.3);border-color:#83c373}.entry-content .llms-notice{margin:0 0 10px}.entry-content .llms-notice li{list-style-type:none}ul.llms-achievements-loop,.lifterlms ul.llms-achievements-loop,ul.llms-certificates-loop,.lifterlms ul.llms-certificates-loop{list-style-type:none;margin:0 -10px;padding:0}ul.llms-achievements-loop:before,ul.llms-achievements-loop:after,.lifterlms ul.llms-achievements-loop:before,.lifterlms ul.llms-achievements-loop:after,ul.llms-certificates-loop:before,ul.llms-certificates-loop:after,.lifterlms ul.llms-certificates-loop:before,.lifterlms ul.llms-certificates-loop:after{content:" ";display:table}ul.llms-achievements-loop:after,.lifterlms ul.llms-achievements-loop:after,ul.llms-certificates-loop:after,.lifterlms ul.llms-certificates-loop:after{clear:both}ul.llms-achievements-loop li.llms-achievement-loop-item,ul.llms-achievements-loop li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop li.llms-certificate-loop-item,ul.llms-certificates-loop li.llms-achievement-loop-item,ul.llms-certificates-loop li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop li.llms-certificate-loop-item{-webkit-box-sizing:border-box;box-sizing:border-box;display:block;float:left;list-style-type:none;margin:0;padding:10px;width:100%}@media all and (min-width: 600px){ul.llms-achievements-loop.loop-cols-1 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-1 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-1 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-1 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-1 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-1 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-1 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-1 li.llms-certificate-loop-item{width:100%}ul.llms-achievements-loop.loop-cols-2 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-2 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-2 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-2 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-2 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-2 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-2 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-2 li.llms-certificate-loop-item{width:50%}ul.llms-achievements-loop.loop-cols-3 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-3 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-3 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-3 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-3 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-3 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-3 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-3 li.llms-certificate-loop-item{width:33.3333333333%}ul.llms-achievements-loop.loop-cols-4 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-4 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-4 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-4 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-4 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-4 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-4 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-4 li.llms-certificate-loop-item{width:25%}ul.llms-achievements-loop.loop-cols-5 li.llms-achievement-loop-item,ul.llms-achievements-loop.loop-cols-5 li.llms-certificate-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-5 li.llms-achievement-loop-item,.lifterlms ul.llms-achievements-loop.loop-cols-5 li.llms-certificate-loop-item,ul.llms-certificates-loop.loop-cols-5 li.llms-achievement-loop-item,ul.llms-certificates-loop.loop-cols-5 li.llms-certificate-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-5 li.llms-achievement-loop-item,.lifterlms ul.llms-certificates-loop.loop-cols-5 li.llms-certificate-loop-item{width:20%}}.llms-achievement,.llms-certificate{background:#f1f1f1;border:none;color:inherit;display:block;text-decoration:none;width:100%}.llms-achievement:hover,.llms-certificate:hover{background:#eaeaea}.llms-achievement .llms-achievement-img,.llms-certificate .llms-achievement-img{display:block;margin:0;width:100%}.llms-achievement .llms-achievement-title,.llms-certificate .llms-achievement-title{font-size:16px;margin:0;padding:10px;text-align:center}.llms-achievement .llms-certificate-title,.llms-certificate .llms-certificate-title{font-size:16px;margin:0;padding:0 0 10px}.llms-achievement .llms-achievement-info,.llms-achievement .llms-achievement-date,.llms-certificate .llms-achievement-info,.llms-certificate .llms-achievement-date{display:none}.llms-achievement .llms-achievement-content,.llms-certificate .llms-achievement-content{padding:20px}.llms-achievement .llms-achievement-content:empty,.llms-certificate .llms-achievement-content:empty{padding:0}.llms-achievement .llms-achievement-content *:last-child,.llms-certificate .llms-achievement-content *:last-child{margin-bottom:0}.llms-certificate{border:4px double #f1f1f1;padding:20px 10px;background:#fff;text-align:center}.llms-certificate:hover{background:#fff;border-color:#eaeaea}.llms-achievement-modal .llms-achievement{background:#fff}.llms-achievement-modal .llms-achievement-info{display:block}.llms-achievement-modal .llms-achievement-title{display:none}.llms-notification{background:#fff;-webkit-box-shadow:0 1px 2px -2px #333,0 1px 1px -1px #333;box-shadow:0 1px 2px -2px #333,0 1px 1px -1px #333;border-top:4px solid #2295ff;opacity:0;padding:12px;position:fixed;right:-800px;top:24px;-webkit-transition:opacity .4s ease-in-out,right .4s ease-in-out;transition:opacity .4s ease-in-out,right .4s ease-in-out;visibility:hidden;width:auto;z-index:9999999}.llms-notification:before,.llms-notification:after{content:" ";display:table}.llms-notification:after{clear:both}.llms-notification.visible{left:12px;opacity:1;right:12px;-webkit-transition:opacity .4s ease-in-out,right .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,-webkit-transform .2s ease-in-out;transition:opacity .4s ease-in-out,right .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,-webkit-transform .2s ease-in-out;transition:opacity .4s ease-in-out,right .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,transform .2s ease-in-out;transition:opacity .4s ease-in-out,right .4s ease-in-out,top .1s ease-in-out,background .2s ease-in-out,transform .2s ease-in-out,-webkit-transform .2s ease-in-out;visibility:visible}.llms-notification.visible:hover .llms-notification-dismiss{opacity:1}.llms-notification .llms-notification-content{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex}.llms-notification .llms-notification-main{-ms-flex-item-align:start;align-self:flex-start;-webkit-box-flex:4;-ms-flex:4;flex:4;-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2}.llms-notification .llms-notification-title{font-size:18px;margin:0}.llms-notification .llms-notification-body{font-size:14px;line-height:1.4}.llms-notification .llms-notification-body p,.llms-notification .llms-notification-body li{font-size:inherit}.llms-notification .llms-notification-body p{margin-bottom:8px}.llms-notification .llms-notification-body .llms-mini-cert{background:#f6f6f6;border:1px solid #d0d0d0;-webkit-box-shadow:inset 0 0 0 3px #fefefe,inset 0 0 0 4px #dedede;box-shadow:inset 0 0 0 3px #fefefe,inset 0 0 0 4px #dedede;padding:16px 16px 24px;margin-top:12px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert-title{font-size:16px;font-weight:700;margin:12px auto;text-align:center}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body{width:100%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(1){width:65%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(2){width:35%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(3){width:85%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(4){width:75%;margin-top:18px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(5){width:70%}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(6){margin-left:12px;margin-bottom:-24px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--body>div:nth-child(7){width:65%;margin-right:12px}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--mock-line{border-radius:2px;height:8px;background:#b0b0b0;background-image:-webkit-gradient(linear, left top, right top, from(#b0b0b0), color-stop(20%, #a0a0a0), color-stop(40%, #b0b0b0), to(#b0b0b0));background-image:linear-gradient(to right, #b0b0b0 0%, #a0a0a0 20%, #b0b0b0 40%, #b0b0b0 100%);background-repeat:no-repeat;margin:4px auto}.llms-notification .llms-notification-body .llms-mini-cert .llms-mini-cert--mock-dot{background:#b0b0b0;border-radius:50%;display:inline-block;content:"";height:24px;width:24px}.llms-notification .llms-notification-body .llms-mini-cert p{margin-bottom:0}.llms-notification .llms-notification-aside{-ms-flex-item-align:start;align-self:flex-start;-webkit-box-flex:1;-ms-flex:1;flex:1;margin-right:12px;-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1}.llms-notification .llms-notification-icon{display:block;max-width:64px}.llms-notification .llms-notification-footer{border-top:1px solid #e5e5e5;font-size:12px;margin-top:12px;padding:6px 6px 0;text-align:right}.llms-notification .llms-notification-dismiss{color:#e5554e;cursor:pointer;font-size:22px;position:absolute;right:10px;top:8px;-webkit-transition:opacity .4s ease-in-out;transition:opacity .4s ease-in-out}.llms-sd-notification-center .llms-notification-list,.llms-sd-notification-center .llms-notification-list-item{list-style-type:none;margin:0;padding:0}.llms-sd-notification-center .llms-notification-list-item:hover .llms-notification{background:#fcfcfc}.llms-sd-notification-center .llms-notification{opacity:1;border-top:1px solid #e5e5e5;left:auto;padding:24px;position:relative;right:auto;top:auto;visibility:visible;width:auto}.llms-sd-notification-center .llms-notification .llms-notification-aside{max-width:64px}.llms-sd-notification-center .llms-notification .llms-notification-footer{border:none;padding:0;text-align:left}.llms-sd-notification-center .llms-notification .llms-progress{display:none !important}.llms-sd-notification-center .llms-notification .llms-notification-date{color:#515151;float:left;margin-right:6px}.llms-sd-notification-center .llms-notification .llms-mini-cert{margin:0 auto;max-width:380px}@media all and (min-width: 480px){.llms-notification{right:-800px;width:360px}.llms-notification.visible{left:auto;right:24px}.llms-notification .llms-notification-dismiss{opacity:0}}.llms-pagination ul{list-style-type:none}.llms-pagination ul li{float:left}.llms-pagination ul li a{border-bottom:0;text-decoration:none}.llms-pagination ul li .page-numbers{padding:.5em;text-decoration:underline}.llms-pagination ul li .page-numbers.current{text-decoration:none}.llms-tooltip{background:#2a2a2a;border-radius:4px;color:#fff;font-size:14px;line-height:1.2;opacity:0;top:-20px;padding:8px 12px;left:50%;position:absolute;pointer-events:none;-webkit-transform:translateX(-50%);transform:translateX(-50%);-webkit-transition:opacity .2s ease,top .2s ease;transition:opacity .2s ease,top .2s ease;max-width:320px}.llms-tooltip.show{top:-28px;opacity:1}.llms-tooltip:after{bottom:-8px;border-top:8px solid #2a2a2a;border-left:8px solid rgba(0,0,0,0);border-right:8px solid rgba(0,0,0,0);content:"";height:0;left:50%;position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%);width:0}.webui-popover-title{font-size:initial;font-weight:initial;line-height:initial}.webui-popover-inverse .webui-popover-inner .close{color:#fff;opacity:.6;text-shadow:none}.webui-popover-inverse .webui-popover-inner .close:hover{opacity:.8}.webui-popover-inverse .webui-popover-content a{color:#fff;text-decoration:underline}.webui-popover-inverse .webui-popover-content a:hover{text-decoration:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results{margin:0;padding:0;list-style-type:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question{background:#efefef;margin:0 0 10px;position:relative;list-style-type:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer{color:inherit;display:block;padding:10px 35px 10px 10px;text-decoration:none}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:before,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:after{content:" ";display:table}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .toggle-answer:after{clear:both}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.correct,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.incorrect{background:rgba(255,146,43,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.correct .llms-status-icon,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--waiting.incorrect .llms-status-icon{background-color:#ff922b}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.correct{background:rgba(131,195,115,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.correct .llms-status-icon{background-color:#83c373}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.incorrect{background:rgba(229,85,78,.2)}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.status--graded.incorrect .llms-status-icon{background-color:#e5554e}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question pre{overflow:auto}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-question-title{float:left;margin:0;line-height:1}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-points{float:right;line-height:1}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-status-icon-tip{position:absolute;right:-12px;top:-2px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-status-icon{color:rgba(255,255,255,.65);border-radius:50%;font-size:30px;height:40px;line-height:40px;text-align:center;width:40px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main{display:none;padding:0 10px 10px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-results-label{font-weight:700;margin-bottom:10px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers{margin:0;padding:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer{padding:0;margin:0 0 0 30px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer:only-child{list-style-type:none;margin-left:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main img{height:auto;max-width:200px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-attempt-answer-section{border-top:2px solid rgba(255,255,255,.5);margin-top:20px;padding-top:20px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question .llms-quiz-attempt-question-main .llms-quiz-attempt-answer-section:first-child{border-top:none;margin-top:0;padding-top:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_choice ul.llms-quiz-attempt-answers,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_reorder ul.llms-quiz-attempt-answers{list-style-type:none;margin:0;padding:0}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_choice ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer,.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--picture_reorder ul.llms-quiz-attempt-answers li.llms-quiz-attempt-answer{display:inline-block;list-style-type:none;margin:0;padding:5px}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--removed{opacity:.5}.single-llms_quiz #llms-quiz-wrapper .llms-quiz-attempt-results .llms-quiz-attempt-question.type--removed .llms-question-title{font-style:italic;font-weight:normal}.single-llms_quiz .llms-return{margin-bottom:10px}.single-llms_quiz .llms-quiz-results:before,.single-llms_quiz .llms-quiz-results:after{content:" ";display:table}.single-llms_quiz .llms-quiz-results:after{clear:both}.single-llms_quiz .llms-quiz-results .llms-donut.passing{color:#83c373}.single-llms_quiz .llms-quiz-results .llms-donut.passing svg path{stroke:#83c373}.single-llms_quiz .llms-quiz-results .llms-donut.pending{color:#555}.single-llms_quiz .llms-quiz-results .llms-donut.pending svg path{stroke:#555}.single-llms_quiz .llms-quiz-results .llms-donut.failing{color:#e5554e}.single-llms_quiz .llms-quiz-results .llms-donut.failing svg path{stroke:#e5554e}.single-llms_quiz .llms-quiz-results .llms-quiz-results-aside,.single-llms_quiz .llms-quiz-results .llms-quiz-results-main,.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{margin-bottom:20px}@media all and (min-width: 600px){.single-llms_quiz .llms-quiz-results .llms-quiz-results-aside{float:left;width:220px}.single-llms_quiz .llms-quiz-results .llms-quiz-results-main,.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{float:right;width:calc(100% - 300px)}.single-llms_quiz .llms-quiz-results .llms-quiz-results-history{clear:right}}.single-llms_quiz ul.llms-quiz-meta-info,.single-llms_quiz ul.llms-quiz-meta-info li{list-style-type:none;margin:0;padding:0}.single-llms_quiz ul.llms-quiz-meta-info{margin-bottom:10px}.single-llms_quiz .llms-quiz-buttons{margin-top:10px;text-align:left}.single-llms_quiz .llms-quiz-buttons form{display:inline-block}.llms-quiz-question-wrapper{min-height:140px;position:relative}.llms-quiz-question-wrapper .llms-quiz-loading{bottom:20px;left:0;position:absolute;right:0;text-align:center;z-index:1}.llms-quiz-ui{background:#fcfcfc;padding:20px;position:relative}.llms-quiz-ui .llms-quiz-header{-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-box;display:-ms-flexbox;display:flex;margin:0 0 30px}.llms-quiz-ui .llms-progress{background-color:#f1f2f1;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;height:8px;margin:0;overflow:hidden}.llms-quiz-ui .llms-progress .progress-bar-complete{-webkit-transition:width .3s ease-in;transition:width .3s ease-in;width:0}.llms-quiz-ui .llms-error{background:#e5554e;border-radius:4px;color:#fff;margin:10px 0;padding:10px}.llms-quiz-ui .llms-error:before,.llms-quiz-ui .llms-error:after{content:" ";display:table}.llms-quiz-ui .llms-error:after{clear:both}.llms-quiz-ui .llms-error a{color:rgba(255,255,255,.6);float:right;font-size:22px;line-height:1;text-decoration:none}.llms-quiz-ui .llms-quiz-counter{display:none;color:#6a6a6a;float:right;font-size:18px}.llms-quiz-ui .llms-quiz-counter .llms-sep{margin:0 5px}.llms-quiz-ui .llms-quiz-nav{margin-top:20px}.llms-quiz-ui .llms-quiz-nav button{margin:0 10px 0 0}.llms-question-wrapper .llms-question-text{font-size:30px;font-weight:400;margin-bottom:15px}.llms-question-wrapper ol.llms-question-choices{list-style-type:none;margin:0;padding:0}.llms-question-wrapper ol.llms-question-choices li.llms-choice{border-bottom:1px solid #e8e8e8;margin:0;padding:0;position:relative}.llms-question-wrapper ol.llms-question-choices li.llms-choice:last-child{border-bottom:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture{border-bottom:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture label{display:inline-block;padding:0}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-marker{bottom:10px;margin:0;position:absolute;right:10px}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-choice-image{margin:2px;padding:20px;-webkit-transition:background .4s ease;transition:background .4s ease}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture .llms-choice-image img{display:block;width:100%}.llms-question-wrapper ol.llms-question-choices li.llms-choice.type--picture input:checked~.llms-choice-image{background:#efefef}.llms-question-wrapper ol.llms-question-choices li.llms-choice input{display:none;left:0;pointer-events:none;position:absolute;top:0;visibility:hidden}.llms-question-wrapper ol.llms-question-choices li.llms-choice label{display:block;margin:0;padding:10px 20px;position:relative}.llms-question-wrapper ol.llms-question-choices li.llms-choice label.hovered .llms-marker:not(.type--lister) .iterator{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice label.hovered .llms-marker:not(.type--lister) .fa{display:inline}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker{background:#f0f0f0;display:inline-block;font-size:20px;height:40px;line-height:40px;margin-right:10px;text-align:center;-webkit-transition:all .2s ease;transition:all .2s ease;vertical-align:middle;width:40px}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker .fa{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--lister,.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--checkbox{border-radius:4px}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-marker.type--radio{border-radius:50%}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker{background:#ef476f;color:#fff}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker .iterator{display:none}.llms-question-wrapper ol.llms-question-choices li.llms-choice input:checked+.llms-marker .fa{display:inline}.llms-question-wrapper ol.llms-question-choices li.llms-choice .llms-choice-text{display:inline-block;font-size:18px;font-weight:400;line-height:1.6;margin-bottom:0;vertical-align:middle;width:calc(100% - 60px)}.llms-quiz-timer{background:#fff;border:1px solid #83c373;border-radius:4px;color:#83c373;float:right;font-size:18px;line-height:1;margin-left:20px;padding:8px 12px;position:relative;white-space:nowrap;z-index:1}.llms-quiz-timer.color-half{border-color:#ff922b;color:#ff922b}.llms-quiz-timer.color-empty{border-color:#e5554e;color:#e5554e}.llms-quiz-timer .llms-tiles{display:inline-block;margin-left:5px}.voucher-expand{display:none}@media all and (min-width: 600px){.llms-access-plans.cols-1 .llms-access-plan{width:100%}.llms-access-plans.cols-2 .llms-access-plan{width:50%}.llms-access-plans.cols-3 .llms-access-plan{width:33.3333333333%}.llms-access-plans.cols-4 .llms-access-plan{width:25%}.llms-access-plans.cols-5 .llms-access-plan{width:20%}}.llms-free-enroll-form{margin-bottom:0}.llms-access-plan{-webkit-box-sizing:border-box;box-sizing:border-box;float:left;text-align:center;width:100%}.llms-access-plan .llms-access-plan-footer,.llms-access-plan .llms-access-plan-content{background:#f1f1f1}.llms-access-plan.featured .llms-access-plan-featured{background:#4ba9ff}.llms-access-plan.featured .llms-access-plan-footer,.llms-access-plan.featured .llms-access-plan-content{border-left:3px solid #2295ff;border-right:3px solid #2295ff}.llms-access-plan.featured .llms-access-plan-footer{border-bottom-color:#2295ff}.llms-access-plan.on-sale .price-regular{text-decoration:line-through}.llms-access-plan .stamp{background:#2295ff;color:#fff;font-size:11px;font-style:normal;font-weight:300;padding:2px 3px;vertical-align:top}.llms-access-plan .llms-access-plan-restrictions ul{margin:0}.llms-access-plan-featured{color:#fff;font-size:14px;font-weight:400;margin:0 2px 0 2px}.llms-access-plan-content{margin:0 2px 0}.llms-access-plan-content .llms-access-plan-pricing{padding:10px 0 0}.llms-access-plan-title{background:#2295ff;color:#fff;margin-bottom:0;padding:10px}.llms-access-plan-pricing .llms-price-currency-symbol{font-size:14px;vertical-align:top}.llms-access-plan-price{font-size:18px;font-variant:small-caps;line-height:20px}.llms-access-plan-price .lifterlms-price{font-weight:700}.llms-access-plan-price.sale{padding:5px 0;border-top:1px solid #d0d0d0;border-bottom:1px solid #d0d0d0}.llms-access-plan-trial,.llms-access-plan-schedule,.llms-access-plan-sale-end,.llms-access-plan-expiration{font-size:15px;font-variant:small-caps;line-height:1.2}.llms-access-plan-description{font-size:16px;padding:10px 10px 0}.llms-access-plan-description ul{margin:0}.llms-access-plan-description ul li{border-bottom:1px solid #d0d0d0;list-style-type:none}.llms-access-plan-description ul li:last-child{border-bottom:none}.llms-access-plan-description div:last-child,.llms-access-plan-description img:last-child,.llms-access-plan-description p:last-child,.llms-access-plan-description ul:last-child,.llms-access-plan-description li:last-child{margin-bottom:0}.llms-access-plan-restrictions .stamp{vertical-align:baseline}.llms-access-plan-restrictions ul{margin:0}.llms-access-plan-restrictions ul li{font-size:12px;line-height:14px;list-style-type:none}.llms-access-plan-restrictions a{color:#f8954f}.llms-access-plan-restrictions a:hover{color:#f67d28}.llms-access-plan-footer{border-bottom:3px solid #f1f1f1;padding:10px;margin:0 2px 2px 2px}.llms-access-plan-footer .llms-access-plan-pricing{padding:0 0 10px}.webui-popover-content .llms-members-only-restrictions{text-align:center}.webui-popover-content .llms-members-only-restrictions ul,.webui-popover-content .llms-members-only-restrictions ol,.webui-popover-content .llms-members-only-restrictions li,.webui-popover-content .llms-members-only-restrictions p{margin:0;padding:0}.webui-popover-content .llms-members-only-restrictions ul,.webui-popover-content .llms-members-only-restrictions ol,.webui-popover-content .llms-members-only-restrictions li{list-style-type:none}.webui-popover-content .llms-members-only-restrictions li{padding:8px 0;border-top:1px solid #3b3b3b}.webui-popover-content .llms-members-only-restrictions li:first-child{border-top:none}.webui-popover-content .llms-members-only-restrictions li a{display:block}.llms-checkout-wrapper form.llms-login{border:3px solid #2295ff;display:none;margin-bottom:10px}.llms-checkout-wrapper .llms-form-heading{background:#2295ff;color:#fff;margin:0 0 5px;padding:10px}.llms-checkout{background:#fff;position:relative}@media all and (min-width: 800px){.llms-checkout-cols-2 .llms-checkout-col{float:left}.llms-checkout-cols-2 .llms-checkout-col.llms-col-1{margin-right:5px;width:calc(58% - 5px)}.llms-checkout-cols-2 .llms-checkout-col.llms-col-2{margin-left:5px;width:calc(42% - 5px)}.llms-checkout-cols-2 .llms-checkout-col.llms-col-2 button{width:100%}}.llms-checkout-section{border:3px solid #2295ff;margin-bottom:10px;position:relative}.llms-checkout-section-content{margin:10px}.llms-checkout-section-content.llms-form-fields{margin:0px}.llms-checkout-section-content .llms-label{font-weight:400;font-variant:small-caps;text-transform:lowercase}.llms-checkout-section-content .llms-order-summary{list-style-type:none;margin:0;padding:0}.llms-checkout-section-content .llms-order-summary li{list-style-type:none}.llms-checkout-section-content .llms-order-summary li.llms-pricing.on-sale .price-regular,.llms-checkout-section-content .llms-order-summary li.llms-pricing.has-coupon .price-regular{text-decoration:line-through}.llms-checkout-section-content .llms-coupon-wrapper{border-top:1px solid #dadada;margin-top:10px;padding-top:10px}.llms-checkout-section-content .llms-coupon-wrapper .llms-coupon-entry{display:none;margin-top:10px}.llms-form-field.llms-payment-gateway-option label+span.llms-description{display:inline-block;margin-left:5px}.llms-form-field.llms-payment-gateway-option .llms-description a{border:none;-webkit-box-shadow:none;box-shadow:none;text-decoration:none}.llms-form-field.llms-payment-gateway-option .llms-description img{display:inline;max-height:22px;vertical-align:middle}.llms-checkout-wrapper ul.llms-payment-gateways{margin:5px 0 0;padding:0}ul.llms-payment-gateways{list-style-type:none}ul.llms-payment-gateways li:last-child:after{border-bottom:1px solid #dadada;content:"";display:block;margin:10px}ul.llms-payment-gateways .llms-payment-gateway{margin-bottom:5px;list-style-type:none}ul.llms-payment-gateways .llms-payment-gateway:last-child{margin-bottom:none}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-payment-gateway-option label{font-weight:700}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-gateway-fields{display:block}ul.llms-payment-gateways .llms-payment-gateway.is-selected .llms-gateway-fields .llms-notice{margin-left:10px;margin-right:10px}ul.llms-payment-gateways .llms-payment-gateway .llms-form-field{padding-bottom:0}ul.llms-payment-gateways .llms-gateway-description{margin-left:40px}ul.llms-payment-gateways .llms-gateway-fields{display:none;margin:5px 0 20px}ul.llms-payment-gateways .llms-payment-gateway-error{padding:0 10px}.llms-checkout-confirm{margin:0 10px}.llms-payment-method{margin:10px 10px 0}.llms-gateway-description p{font-size:85%;font-style:italic;margin-bottom:0}.llms-form-fields{-webkit-box-sizing:border-box;box-sizing:border-box}.llms-form-fields *{-webkit-box-sizing:border-box;box-sizing:border-box}.llms-form-fields.flush .llms-form-field{padding:0 0 10px}.llms-form-fields .wp-block-columns,.llms-form-fields .wp-block-column{margin-bottom:0}.llms-form-heading{padding:0 10px 10px}.llms-form-field{float:left;padding:0 10px 10px;position:relative;width:100%}.llms-form-field label:empty:after{content:" "}.llms-form-field.valid input[type=date],.llms-form-field.valid input[type=time],.llms-form-field.valid input[type=datetime-local],.llms-form-field.valid input[type=week],.llms-form-field.valid input[type=month],.llms-form-field.valid input[type=text],.llms-form-field.valid input[type=email],.llms-form-field.valid input[type=url],.llms-form-field.valid input[type=password],.llms-form-field.valid input[type=search],.llms-form-field.valid input[type=tel],.llms-form-field.valid input[type=number],.llms-form-field.valid textarea,.llms-form-field.valid select{background:rgba(131,195,115,.3);border-color:#83c373}.llms-form-field.error input[type=date],.llms-form-field.error input[type=time],.llms-form-field.error input[type=datetime-local],.llms-form-field.error input[type=week],.llms-form-field.error input[type=month],.llms-form-field.error input[type=text],.llms-form-field.error input[type=email],.llms-form-field.error input[type=url],.llms-form-field.error input[type=password],.llms-form-field.error input[type=search],.llms-form-field.error input[type=tel],.llms-form-field.error input[type=number],.llms-form-field.error textarea,.llms-form-field.error select,.llms-form-field.invalid input[type=date],.llms-form-field.invalid input[type=time],.llms-form-field.invalid input[type=datetime-local],.llms-form-field.invalid input[type=week],.llms-form-field.invalid input[type=month],.llms-form-field.invalid input[type=text],.llms-form-field.invalid input[type=email],.llms-form-field.invalid input[type=url],.llms-form-field.invalid input[type=password],.llms-form-field.invalid input[type=search],.llms-form-field.invalid input[type=tel],.llms-form-field.invalid input[type=number],.llms-form-field.invalid textarea,.llms-form-field.invalid select{background:rgba(229,85,78,.3);border-color:#e5554e}.llms-form-field.llms-visually-hidden-field{display:none}.llms-form-field.align-right{text-align:right}@media screen and (min-width: 600px){.llms-form-field.llms-cols-1{width:8.3333333333%}.llms-form-field.llms-cols-2{width:16.6666666667%}.llms-form-field.llms-cols-3{width:25%}.llms-form-field.llms-cols-4{width:33.3333333333%}.llms-form-field.llms-cols-5{width:41.6666666667%}.llms-form-field.llms-cols-6{width:50%}.llms-form-field.llms-cols-7{width:58.3333333333%}.llms-form-field.llms-cols-8{width:66.6666666667%}.llms-form-field.llms-cols-9{width:75%}.llms-form-field.llms-cols-10{width:83.3333333333%}.llms-form-field.llms-cols-11{width:91.6666666667%}.llms-form-field.llms-cols-12{width:100%}}.llms-form-field.type-hidden{padding:0}.llms-form-field.type-radio input,.llms-form-field.type-radio label,.llms-form-field.type-checkbox input,.llms-form-field.type-checkbox label{display:inline-block;width:auto}.llms-form-field.type-radio input,.llms-form-field.type-checkbox input{margin-right:5px}.llms-form-field.type-radio label+.llms-description,.llms-form-field.type-checkbox label+.llms-description{display:block}.llms-form-field.type-radio:not(.is-group) input[type=radio]{position:absolute;opacity:0;visibility:none}.llms-form-field.type-radio:not(.is-group) label:before{background:#fafafa;background-position:-24px 0;background-repeat:no-repeat;border-radius:50%;-webkit-box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.35) 0 0 0 1px;box-shadow:rgba(255,255,255,.15) 0 1px 1px,inset rgba(0,0,0,.35) 0 0 0 1px;content:"";cursor:pointer;display:inline-block;height:22px;margin-right:5px;position:relative;-webkit-transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);transition:background-position .15s cubic-bezier(0.8, 0, 1, 1);top:-3px;vertical-align:middle;width:22px;z-index:2}.llms-form-field.type-radio:not(.is-group) input[type=radio]:checked+label:before{-webkit-transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);transition:background-position .2s .15s cubic-bezier(0, 0, 0.2, 1);background-position:0 0;background-image:radial-gradient(ellipse at center, #2295ff 0%, #2295ff 40%, #fafafa 45%)}.llms-form-field .llms-input-group{margin-top:5px}.llms-form-field .llms-input-group .llms-form-field{padding:0 0 5px 5px}.llms-form-field.type-reset button:not(.auto),.llms-form-field.type-button button:not(.auto),.llms-form-field.type-submit button:not(.auto){width:100%}.llms-form-field .llms-description{font-size:14px;font-style:italic}.llms-form-field .llms-required{color:#e5554e;margin-left:4px}.llms-form-field input,.llms-form-field textarea,.llms-form-field select{width:100%;margin-bottom:5px}.llms-form-field .select2-container .select2-selection--single{height:auto;padding:4px 6px}.llms-form-field .select2-container--default .select2-selection--single .select2-selection__arrow{height:100%}.llms-password-strength-meter{border:1px solid #dadada;display:none;font-size:10px;margin-top:-10px;padding:1px;position:relative;text-align:center}.llms-password-strength-meter:before{bottom:0;content:"";left:0;position:absolute;top:0;-webkit-transition:width .4s ease;transition:width .4s ease}.llms-password-strength-meter.mismatch,.llms-password-strength-meter.too-short,.llms-password-strength-meter.very-weak{border-color:#e35b5b}.llms-password-strength-meter.mismatch:before,.llms-password-strength-meter.too-short:before,.llms-password-strength-meter.very-weak:before{background:rgba(227,91,91,.25);width:25%}.llms-password-strength-meter.too-short:before{width:0}.llms-password-strength-meter.weak{border-color:#f78b53}.llms-password-strength-meter.weak:before{background:rgba(247,139,83,.25);width:50%}.llms-password-strength-meter.medium{border-color:#ffc733}.llms-password-strength-meter.medium:before{background:rgba(255,199,51,.25);width:75%}.llms-password-strength-meter.strong{border-color:#83c373}.llms-password-strength-meter.strong:before{background:rgba(131,195,115,.25);width:100%}.llms-widget-syllabus--collapsible .llms-section .section-header{cursor:pointer}.llms-widget-syllabus--collapsible .llms-section.llms-section--opened .llms-collapse-caret .fa-caret-right{display:none}.llms-widget-syllabus--collapsible .llms-section.llms-section--closed .llms-collapse-caret .fa-caret-down{display:none}.llms-widget-syllabus--collapsible .llms-section.llms-section--closed .llms-lesson{display:none}.llms-widget-syllabus--collapsible .llms-syllabus-footer{text-align:left}.llms-student-dashboard .llms-sd-title{margin:25px 0}.llms-student-dashboard .llms-sd-items{list-style-type:none;margin:0;padding:0}.llms-student-dashboard .llms-sd-item{float:left;list-style-type:none;margin:0;padding:0}.llms-student-dashboard .llms-sd-item:last-child .llms-sep{display:none}.llms-student-dashboard .llms-sd-item .llms-sep{color:#333;margin:0 5px}.llms-student-dashboard .llms-sd-section{margin-bottom:25px}.llms-student-dashboard .llms-sd-section .llms-sd-section-footer{margin-top:10px}.llms-student-dashboard .orders-table{border:1px solid #f5f5f5;width:100%}.llms-student-dashboard .orders-table thead{display:none}.llms-student-dashboard .orders-table thead th,.llms-student-dashboard .orders-table thead td{font-weight:700}@media all and (min-width: 600px){.llms-student-dashboard .orders-table thead{display:table-header-group}}.llms-student-dashboard .orders-table tbody tr:nth-child(even) td,.llms-student-dashboard .orders-table tbody tr:nth-child(even) th{background:#f9f9f9}.llms-student-dashboard .orders-table tfoot th,.llms-student-dashboard .orders-table tfoot td{padding:10px;text-align:right}.llms-student-dashboard .orders-table tfoot th:last-child,.llms-student-dashboard .orders-table tfoot td:last-child{border-bottom-width:0}.llms-student-dashboard .orders-table th{font-weight:700}.llms-student-dashboard .orders-table th,.llms-student-dashboard .orders-table td{border-color:#efefef;border-style:solid;border-width:0;display:block;padding:8px 12px;text-align:center}.llms-student-dashboard .orders-table th .llms-button-primary,.llms-student-dashboard .orders-table td .llms-button-primary{display:inline-block}.llms-student-dashboard .orders-table th:last-child,.llms-student-dashboard .orders-table td:last-child{border-bottom-width:1px}.llms-student-dashboard .orders-table th:before,.llms-student-dashboard .orders-table td:before{content:attr(data-label)}@media all and (min-width: 600px){.llms-student-dashboard .orders-table th,.llms-student-dashboard .orders-table td{border-bottom-width:1px;display:table-cell;text-align:left}.llms-student-dashboard .orders-table th:first-child,.llms-student-dashboard .orders-table td:first-child{width:220px}.llms-student-dashboard .orders-table th:before,.llms-student-dashboard .orders-table td:before{display:none}}@media all and (min-width: 600px){.llms-student-dashboard .orders-table.transactions th:first-child{width:auto}}.llms-student-dashboard .llms-status{border-radius:3px;border-bottom:1px solid #fff;display:inline-block;font-size:80%;padding:3px 6px;vertical-align:middle}.llms-student-dashboard .llms-status.llms-size--large{font-size:105%;padding:6px 12px}.llms-student-dashboard .llms-status.llms-active,.llms-student-dashboard .llms-status.llms-completed,.llms-student-dashboard .llms-status.llms-pass,.llms-student-dashboard .llms-status.llms-txn-succeeded{color:#1f3818;background-color:#83c373}.llms-student-dashboard .llms-status.llms-fail,.llms-student-dashboard .llms-status.llms-failed,.llms-student-dashboard .llms-status.llms-expired,.llms-student-dashboard .llms-status.llms-cancelled,.llms-student-dashboard .llms-status.llms-txn-failed{color:#5a110d;background-color:#e5554e}.llms-student-dashboard .llms-status.llms-incomplete,.llms-student-dashboard .llms-status.llms-on-hold,.llms-student-dashboard .llms-status.llms-pending,.llms-student-dashboard .llms-status.llms-pending-cancel,.llms-student-dashboard .llms-status.llms-refunded,.llms-student-dashboard .llms-status.llms-txn-pending,.llms-student-dashboard .llms-status.llms-txn-refunded{color:#664200;background-color:orange}.llms-student-dashboard .llms-person-form-wrapper .llms-change-password{display:none}@media all and (min-width: 600px){.llms-student-dashboard .order-primary{float:left;width:68%}}@media all and (min-width: 600px){.llms-student-dashboard .order-secondary{float:left;width:32%}}.llms-student-dashboard .order-secondary form{margin-bottom:0}@media all and (min-width: 600px){.llms-student-dashboard .llms-view-order.llms-stack-cols .order-primary,.llms-student-dashboard .llms-view-order.llms-stack-cols .order-secondary{float:none;width:100%}}.llms-student-dashboard .llms-switch-payment-source .llms-notice,.llms-student-dashboard .llms-switch-payment-source .entry-content .llms-notice{margin-left:10px;margin-right:10px}.llms-student-dashboard .llms-switch-payment-source-main{border:none;display:none;margin:0}.llms-student-dashboard .llms-switch-payment-source-main ul.llms-payment-gateways{padding:10px 15px 0;margin:0}.llms-student-dashboard .llms-switch-payment-source-main .llms-payment-method,.llms-student-dashboard .llms-switch-payment-source-main ul.llms-order-summary{padding:0 25px 10px;margin:0;list-style-type:none}.llms-student-dashboard .llms-switch-payment-source-main .llms-payment-method li,.llms-student-dashboard .llms-switch-payment-source-main ul.llms-order-summary li{list-style-type:none}.llms-student-dashboard .llms-loop-list{margin:0 -10px}.llms-sd-grades .llms-table .llms-progress{display:block;margin:0}.llms-sd-grades .llms-table .llms-progress .llms-progress-bar{top:0;height:1.4em}.llms-sd-grades .llms-table .llms-progress .progress__indicator{font-size:1em;position:relative;right:.4em;top:.2em;z-index:1}.llms-table.llms-single-course-grades tbody tr:first-child td,.llms-table.llms-single-course-grades tbody tr:first-child th{background-color:#eaeaea}.llms-table.llms-single-course-grades th{font-weight:400}.llms-table.llms-single-course-grades td .llms-donut{display:inline-block;vertical-align:middle}.llms-table.llms-single-course-grades td .llms-status{margin-right:4px}.llms-table.llms-single-course-grades td .llms-donut+.llms-status{margin-left:4px}.llms-table.llms-single-course-grades th.llms-section_title{font-size:110%;font-weight:700}.llms-table.llms-single-course-grades td.llms-lesson_title{padding-left:36px;max-width:40%}.llms-table.llms-single-course-grades td.llms-associated_quiz .llms-donut{display:inline-block;margin-right:5px;vertical-align:middle}.llms-table.llms-single-course-grades td.llms-lesson_title a[href="#"]{pointer-events:none}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"]{color:inherit;position:relative}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"] .llms-tooltip{max-width:380px;width:380px}.llms-table.llms-single-course-grades td.llms-lesson_title a[href^="#"] .llms-tooltip.show{top:-54px}.llms-sd-widgets{display:-webkit-box;display:-ms-flexbox;display:flex}.llms-sd-widgets .llms-sd-widget{background:#f9f9f9;-webkit-box-flex:1;-ms-flex:1;flex:1;margin:10px 10px 20px;padding:0 0 20px}.llms-sd-widgets .llms-sd-widget:first-child{margin-left:0}.llms-sd-widgets .llms-sd-widget:last-child{margin-right:0}.llms-sd-widgets .llms-sd-widget .llms-sd-widget-title{background:#2295ff;color:#fff;font-size:18px;line-height:1;margin:0 0 20px;padding:10px}.llms-sd-widgets .llms-sd-widget .llms-sd-widget-empty{font-size:14px;font-style:italic;opacity:.5;text-align:center}.llms-sd-widgets .llms-sd-widget .llms-donut{margin:0 auto}.llms-sd-widgets .llms-sd-widget .llms-sd-date{opacity:.8;text-align:center;font-size:22px;line-height:1.1}.llms-sd-widgets .llms-sd-widget .llms-sd-date span{display:block}.llms-sd-widgets .llms-sd-widget .llms-sd-date span.day{font-size:52px}.llms-sd-widgets .llms-sd-widget .llms-sd-date span.diff{font-size:12px;font-style:italic;margin-top:8px;opacity:.75}.llms-sd-widgets .llms-sd-widget .llms-achievement{background:rgba(0,0,0,0);margin:0 auto;max-width:120px}.llms-sd-widgets .llms-sd-widget .llms-achievement .llms-achievement-title{display:none}.llms-sd-pagination{margin-top:24px}.llms-sd-pagination:before,.llms-sd-pagination:after{content:" ";display:table}.llms-sd-pagination:after{clear:both}.llms-sd-pagination .llms-button-secondary{display:inline-block}.llms-sd-pagination .llms-button-secondary.prev{float:left}.llms-sd-pagination .llms-button-secondary.next{float:right}.llms-sd-notification-center .llms-notification{z-index:1}.llms-table{border:1px solid #efefef;width:100%}.llms-table thead th,.llms-table thead td{font-weight:700}.llms-table tbody tr:nth-child(odd) td,.llms-table tbody tr:nth-child(odd) th{background:#f9f9f9}.llms-table tbody tr:last-child{border-bottom-width:0}.llms-table tfoot tr{background:#f9f9f9}.llms-table tfoot tr .llms-pagination .page-numbers{margin:0}.llms-table tfoot tr .llms-table-sort{text-align:right}.llms-table tfoot tr .llms-table-sort form,.llms-table tfoot tr .llms-table-sort select,.llms-table tfoot tr .llms-table-sort input,.llms-table tfoot tr .llms-table-sort button{margin:0}.llms-table th{font-weight:700}.llms-table th,.llms-table td{border-bottom:1px solid #efefef;padding:8px 12px}.llms-table th:first-child,.llms-table td:first-child{padding-left:12px}.llms-table th:last-child,.llms-table td:last-child{padding-right:12px}#page .llms-table tfoot label{display:inline}#page .llms-table tfoot select{height:auto}/*! * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) */@font-face{font-family:"FontAwesome";src:url("../fonts/fontawesome-webfont.eot?v=4.7.0");src:url("../fonts/fontawesome-webfont.eot?#iefix&v=4.7.0") format("embedded-opentype"),url("../fonts/fontawesome-webfont.woff2?v=4.7.0") format("woff2"),url("../fonts/fontawesome-webfont.woff?v=4.7.0") format("woff"),url("../fonts/fontawesome-webfont.ttf?v=4.7.0") format("truetype"),url("../fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular") format("svg");font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571429em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.fa-li.fa-lg{left:-1.85714286em}.fa-border{padding:.2em .25em .15em;border:solid .08em #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left{margin-right:.3em}.fa.fa-pull-right{margin-left:.3em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left{margin-right:.3em}.fa.pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{-webkit-filter:none;filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:""}.fa-music:before{content:""}.fa-search:before{content:""}.fa-envelope-o:before{content:""}.fa-heart:before{content:""}.fa-star:before{content:""}.fa-star-o:before{content:""}.fa-user:before{content:""}.fa-film:before{content:""}.fa-th-large:before{content:""}.fa-th:before{content:""}.fa-th-list:before{content:""}.fa-check:before{content:""}.fa-remove:before,.fa-close:before,.fa-times:before{content:""}.fa-search-plus:before{content:""}.fa-search-minus:before{content:""}.fa-power-off:before{content:""}.fa-signal:before{content:""}.fa-gear:before,.fa-cog:before{content:""}.fa-trash-o:before{content:""}.fa-home:before{content:""}.fa-file-o:before{content:""}.fa-clock-o:before{content:""}.fa-road:before{content:""}.fa-download:before{content:""}.fa-arrow-circle-o-down:before{content:""}.fa-arrow-circle-o-up:before{content:""}.fa-inbox:before{content:""}.fa-play-circle-o:before{content:""}.fa-rotate-right:before,.fa-repeat:before{content:""}.fa-refresh:before{content:""}.fa-list-alt:before{content:""}.fa-lock:before{content:""}.fa-flag:before{content:""}.fa-headphones:before{content:""}.fa-volume-off:before{content:""}.fa-volume-down:before{content:""}.fa-volume-up:before{content:""}.fa-qrcode:before{content:""}.fa-barcode:before{content:""}.fa-tag:before{content:""}.fa-tags:before{content:""}.fa-book:before{content:""}.fa-bookmark:before{content:""}.fa-print:before{content:""}.fa-camera:before{content:""}.fa-font:before{content:""}.fa-bold:before{content:""}.fa-italic:before{content:""}.fa-text-height:before{content:""}.fa-text-width:before{content:""}.fa-align-left:before{content:""}.fa-align-center:before{content:""}.fa-align-right:before{content:""}.fa-align-justify:before{content:""}.fa-list:before{content:""}.fa-dedent:before,.fa-outdent:before{content:""}.fa-indent:before{content:""}.fa-video-camera:before{content:""}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:""}.fa-pencil:before{content:""}.fa-map-marker:before{content:""}.fa-adjust:before{content:""}.fa-tint:before{content:""}.fa-edit:before,.fa-pencil-square-o:before{content:""}.fa-share-square-o:before{content:""}.fa-check-square-o:before{content:""}.fa-arrows:before{content:""}.fa-step-backward:before{content:""}.fa-fast-backward:before{content:""}.fa-backward:before{content:""}.fa-play:before{content:""}.fa-pause:before{content:""}.fa-stop:before{content:""}.fa-forward:before{content:""}.fa-fast-forward:before{content:""}.fa-step-forward:before{content:""}.fa-eject:before{content:""}.fa-chevron-left:before{content:""}.fa-chevron-right:before{content:""}.fa-plus-circle:before{content:""}.fa-minus-circle:before{content:""}.fa-times-circle:before{content:""}.fa-check-circle:before{content:""}.fa-question-circle:before{content:""}.fa-info-circle:before{content:""}.fa-crosshairs:before{content:""}.fa-times-circle-o:before{content:""}.fa-check-circle-o:before{content:""}.fa-ban:before{content:""}.fa-arrow-left:before{content:""}.fa-arrow-right:before{content:""}.fa-arrow-up:before{content:""}.fa-arrow-down:before{content:""}.fa-mail-forward:before,.fa-share:before{content:""}.fa-expand:before{content:""}.fa-compress:before{content:""}.fa-plus:before{content:""}.fa-minus:before{content:""}.fa-asterisk:before{content:""}.fa-exclamation-circle:before{content:""}.fa-gift:before{content:""}.fa-leaf:before{content:""}.fa-fire:before{content:""}.fa-eye:before{content:""}.fa-eye-slash:before{content:""}.fa-warning:before,.fa-exclamation-triangle:before{content:""}.fa-plane:before{content:""}.fa-calendar:before{content:""}.fa-random:before{content:""}.fa-comment:before{content:""}.fa-magnet:before{content:""}.fa-chevron-up:before{content:""}.fa-chevron-down:before{content:""}.fa-retweet:before{content:""}.fa-shopping-cart:before{content:""}.fa-folder:before{content:""}.fa-folder-open:before{content:""}.fa-arrows-v:before{content:""}.fa-arrows-h:before{content:""}.fa-bar-chart-o:before,.fa-bar-chart:before{content:""}.fa-twitter-square:before{content:""}.fa-facebook-square:before{content:""}.fa-camera-retro:before{content:""}.fa-key:before{content:""}.fa-gears:before,.fa-cogs:before{content:""}.fa-comments:before{content:""}.fa-thumbs-o-up:before{content:""}.fa-thumbs-o-down:before{content:""}.fa-star-half:before{content:""}.fa-heart-o:before{content:""}.fa-sign-out:before{content:""}.fa-linkedin-square:before{content:""}.fa-thumb-tack:before{content:""}.fa-external-link:before{content:""}.fa-sign-in:before{content:""}.fa-trophy:before{content:""}.fa-github-square:before{content:""}.fa-upload:before{content:""}.fa-lemon-o:before{content:""}.fa-phone:before{content:""}.fa-square-o:before{content:""}.fa-bookmark-o:before{content:""}.fa-phone-square:before{content:""}.fa-twitter:before{content:""}.fa-facebook-f:before,.fa-facebook:before{content:""}.fa-github:before{content:""}.fa-unlock:before{content:""}.fa-credit-card:before{content:""}.fa-feed:before,.fa-rss:before{content:""}.fa-hdd-o:before{content:""}.fa-bullhorn:before{content:""}.fa-bell:before{content:""}.fa-certificate:before{content:""}.fa-hand-o-right:before{content:""}.fa-hand-o-left:before{content:""}.fa-hand-o-up:before{content:""}.fa-hand-o-down:before{content:""}.fa-arrow-circle-left:before{content:""}.fa-arrow-circle-right:before{content:""}.fa-arrow-circle-up:before{content:""}.fa-arrow-circle-down:before{content:""}.fa-globe:before{content:""}.fa-wrench:before{content:""}.fa-tasks:before{content:""}.fa-filter:before{content:""}.fa-briefcase:before{content:""}.fa-arrows-alt:before{content:""}.fa-group:before,.fa-users:before{content:""}.fa-chain:before,.fa-link:before{content:""}.fa-cloud:before{content:""}.fa-flask:before{content:""}.fa-cut:before,.fa-scissors:before{content:""}.fa-copy:before,.fa-files-o:before{content:""}.fa-paperclip:before{content:""}.fa-save:before,.fa-floppy-o:before{content:""}.fa-square:before{content:""}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:""}.fa-list-ul:before{content:""}.fa-list-ol:before{content:""}.fa-strikethrough:before{content:""}.fa-underline:before{content:""}.fa-table:before{content:""}.fa-magic:before{content:""}.fa-truck:before{content:""}.fa-pinterest:before{content:""}.fa-pinterest-square:before{content:""}.fa-google-plus-square:before{content:""}.fa-google-plus:before{content:""}.fa-money:before{content:""}.fa-caret-down:before{content:""}.fa-caret-up:before{content:""}.fa-caret-left:before{content:""}.fa-caret-right:before{content:""}.fa-columns:before{content:""}.fa-unsorted:before,.fa-sort:before{content:""}.fa-sort-down:before,.fa-sort-desc:before{content:""}.fa-sort-up:before,.fa-sort-asc:before{content:""}.fa-envelope:before{content:""}.fa-linkedin:before{content:""}.fa-rotate-left:before,.fa-undo:before{content:""}.fa-legal:before,.fa-gavel:before{content:""}.fa-dashboard:before,.fa-tachometer:before{content:""}.fa-comment-o:before{content:""}.fa-comments-o:before{content:""}.fa-flash:before,.fa-bolt:before{content:""}.fa-sitemap:before{content:""}.fa-umbrella:before{content:""}.fa-paste:before,.fa-clipboard:before{content:""}.fa-lightbulb-o:before{content:""}.fa-exchange:before{content:""}.fa-cloud-download:before{content:""}.fa-cloud-upload:before{content:""}.fa-user-md:before{content:""}.fa-stethoscope:before{content:""}.fa-suitcase:before{content:""}.fa-bell-o:before{content:""}.fa-coffee:before{content:""}.fa-cutlery:before{content:""}.fa-file-text-o:before{content:""}.fa-building-o:before{content:""}.fa-hospital-o:before{content:""}.fa-ambulance:before{content:""}.fa-medkit:before{content:""}.fa-fighter-jet:before{content:""}.fa-beer:before{content:""}.fa-h-square:before{content:""}.fa-plus-square:before{content:""}.fa-angle-double-left:before{content:""}.fa-angle-double-right:before{content:""}.fa-angle-double-up:before{content:""}.fa-angle-double-down:before{content:""}.fa-angle-left:before{content:""}.fa-angle-right:before{content:""}.fa-angle-up:before{content:""}.fa-angle-down:before{content:""}.fa-desktop:before{content:""}.fa-laptop:before{content:""}.fa-tablet:before{content:""}.fa-mobile-phone:before,.fa-mobile:before{content:""}.fa-circle-o:before{content:""}.fa-quote-left:before{content:""}.fa-quote-right:before{content:""}.fa-spinner:before{content:""}.fa-circle:before{content:""}.fa-mail-reply:before,.fa-reply:before{content:""}.fa-github-alt:before{content:""}.fa-folder-o:before{content:""}.fa-folder-open-o:before{content:""}.fa-smile-o:before{content:""}.fa-frown-o:before{content:""}.fa-meh-o:before{content:""}.fa-gamepad:before{content:""}.fa-keyboard-o:before{content:""}.fa-flag-o:before{content:""}.fa-flag-checkered:before{content:""}.fa-terminal:before{content:""}.fa-code:before{content:""}.fa-mail-reply-all:before,.fa-reply-all:before{content:""}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:""}.fa-location-arrow:before{content:""}.fa-crop:before{content:""}.fa-code-fork:before{content:""}.fa-unlink:before,.fa-chain-broken:before{content:""}.fa-question:before{content:""}.fa-info:before{content:""}.fa-exclamation:before{content:""}.fa-superscript:before{content:""}.fa-subscript:before{content:""}.fa-eraser:before{content:""}.fa-puzzle-piece:before{content:""}.fa-microphone:before{content:""}.fa-microphone-slash:before{content:""}.fa-shield:before{content:""}.fa-calendar-o:before{content:""}.fa-fire-extinguisher:before{content:""}.fa-rocket:before{content:""}.fa-maxcdn:before{content:""}.fa-chevron-circle-left:before{content:""}.fa-chevron-circle-right:before{content:""}.fa-chevron-circle-up:before{content:""}.fa-chevron-circle-down:before{content:""}.fa-html5:before{content:""}.fa-css3:before{content:""}.fa-anchor:before{content:""}.fa-unlock-alt:before{content:""}.fa-bullseye:before{content:""}.fa-ellipsis-h:before{content:""}.fa-ellipsis-v:before{content:""}.fa-rss-square:before{content:""}.fa-play-circle:before{content:""}.fa-ticket:before{content:""}.fa-minus-square:before{content:""}.fa-minus-square-o:before{content:""}.fa-level-up:before{content:""}.fa-level-down:before{content:""}.fa-check-square:before{content:""}.fa-pencil-square:before{content:""}.fa-external-link-square:before{content:""}.fa-share-square:before{content:""}.fa-compass:before{content:""}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:""}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:""}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:""}.fa-euro:before,.fa-eur:before{content:""}.fa-gbp:before{content:""}.fa-dollar:before,.fa-usd:before{content:""}.fa-rupee:before,.fa-inr:before{content:""}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:""}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:""}.fa-won:before,.fa-krw:before{content:""}.fa-bitcoin:before,.fa-btc:before{content:""}.fa-file:before{content:""}.fa-file-text:before{content:""}.fa-sort-alpha-asc:before{content:""}.fa-sort-alpha-desc:before{content:""}.fa-sort-amount-asc:before{content:""}.fa-sort-amount-desc:before{content:""}.fa-sort-numeric-asc:before{content:""}.fa-sort-numeric-desc:before{content:""}.fa-thumbs-up:before{content:""}.fa-thumbs-down:before{content:""}.fa-youtube-square:before{content:""}.fa-youtube:before{content:""}.fa-xing:before{content:""}.fa-xing-square:before{content:""}.fa-youtube-play:before{content:""}.fa-dropbox:before{content:""}.fa-stack-overflow:before{content:""}.fa-instagram:before{content:""}.fa-flickr:before{content:""}.fa-adn:before{content:""}.fa-bitbucket:before{content:""}.fa-bitbucket-square:before{content:""}.fa-tumblr:before{content:""}.fa-tumblr-square:before{content:""}.fa-long-arrow-down:before{content:""}.fa-long-arrow-up:before{content:""}.fa-long-arrow-left:before{content:""}.fa-long-arrow-right:before{content:""}.fa-apple:before{content:""}.fa-windows:before{content:""}.fa-android:before{content:""}.fa-linux:before{content:""}.fa-dribbble:before{content:""}.fa-skype:before{content:""}.fa-foursquare:before{content:""}.fa-trello:before{content:""}.fa-female:before{content:""}.fa-male:before{content:""}.fa-gittip:before,.fa-gratipay:before{content:""}.fa-sun-o:before{content:""}.fa-moon-o:before{content:""}.fa-archive:before{content:""}.fa-bug:before{content:""}.fa-vk:before{content:""}.fa-weibo:before{content:""}.fa-renren:before{content:""}.fa-pagelines:before{content:""}.fa-stack-exchange:before{content:""}.fa-arrow-circle-o-right:before{content:""}.fa-arrow-circle-o-left:before{content:""}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:""}.fa-dot-circle-o:before{content:""}.fa-wheelchair:before{content:""}.fa-vimeo-square:before{content:""}.fa-turkish-lira:before,.fa-try:before{content:""}.fa-plus-square-o:before{content:""}.fa-space-shuttle:before{content:""}.fa-slack:before{content:""}.fa-envelope-square:before{content:""}.fa-wordpress:before{content:""}.fa-openid:before{content:""}.fa-institution:before,.fa-bank:before,.fa-university:before{content:""}.fa-mortar-board:before,.fa-graduation-cap:before{content:""}.fa-yahoo:before{content:""}.fa-google:before{content:""}.fa-reddit:before{content:""}.fa-reddit-square:before{content:""}.fa-stumbleupon-circle:before{content:""}.fa-stumbleupon:before{content:""}.fa-delicious:before{content:""}.fa-digg:before{content:""}.fa-pied-piper-pp:before{content:""}.fa-pied-piper-alt:before{content:""}.fa-drupal:before{content:""}.fa-joomla:before{content:""}.fa-language:before{content:""}.fa-fax:before{content:""}.fa-building:before{content:""}.fa-child:before{content:""}.fa-paw:before{content:""}.fa-spoon:before{content:""}.fa-cube:before{content:""}.fa-cubes:before{content:""}.fa-behance:before{content:""}.fa-behance-square:before{content:""}.fa-steam:before{content:""}.fa-steam-square:before{content:""}.fa-recycle:before{content:""}.fa-automobile:before,.fa-car:before{content:""}.fa-cab:before,.fa-taxi:before{content:""}.fa-tree:before{content:""}.fa-spotify:before{content:""}.fa-deviantart:before{content:""}.fa-soundcloud:before{content:""}.fa-database:before{content:""}.fa-file-pdf-o:before{content:""}.fa-file-word-o:before{content:""}.fa-file-excel-o:before{content:""}.fa-file-powerpoint-o:before{content:""}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:""}.fa-file-zip-o:before,.fa-file-archive-o:before{content:""}.fa-file-sound-o:before,.fa-file-audio-o:before{content:""}.fa-file-movie-o:before,.fa-file-video-o:before{content:""}.fa-file-code-o:before{content:""}.fa-vine:before{content:""}.fa-codepen:before{content:""}.fa-jsfiddle:before{content:""}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:""}.fa-circle-o-notch:before{content:""}.fa-ra:before,.fa-resistance:before,.fa-rebel:before{content:""}.fa-ge:before,.fa-empire:before{content:""}.fa-git-square:before{content:""}.fa-git:before{content:""}.fa-y-combinator-square:before,.fa-yc-square:before,.fa-hacker-news:before{content:""}.fa-tencent-weibo:before{content:""}.fa-qq:before{content:""}.fa-wechat:before,.fa-weixin:before{content:""}.fa-send:before,.fa-paper-plane:before{content:""}.fa-send-o:before,.fa-paper-plane-o:before{content:""}.fa-history:before{content:""}.fa-circle-thin:before{content:""}.fa-header:before{content:""}.fa-paragraph:before{content:""}.fa-sliders:before{content:""}.fa-share-alt:before{content:""}.fa-share-alt-square:before{content:""}.fa-bomb:before{content:""}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:""}.fa-tty:before{content:""}.fa-binoculars:before{content:""}.fa-plug:before{content:""}.fa-slideshare:before{content:""}.fa-twitch:before{content:""}.fa-yelp:before{content:""}.fa-newspaper-o:before{content:""}.fa-wifi:before{content:""}.fa-calculator:before{content:""}.fa-paypal:before{content:""}.fa-google-wallet:before{content:""}.fa-cc-visa:before{content:""}.fa-cc-mastercard:before{content:""}.fa-cc-discover:before{content:""}.fa-cc-amex:before{content:""}.fa-cc-paypal:before{content:""}.fa-cc-stripe:before{content:""}.fa-bell-slash:before{content:""}.fa-bell-slash-o:before{content:""}.fa-trash:before{content:""}.fa-copyright:before{content:""}.fa-at:before{content:""}.fa-eyedropper:before{content:""}.fa-paint-brush:before{content:""}.fa-birthday-cake:before{content:""}.fa-area-chart:before{content:""}.fa-pie-chart:before{content:""}.fa-line-chart:before{content:""}.fa-lastfm:before{content:""}.fa-lastfm-square:before{content:""}.fa-toggle-off:before{content:""}.fa-toggle-on:before{content:""}.fa-bicycle:before{content:""}.fa-bus:before{content:""}.fa-ioxhost:before{content:""}.fa-angellist:before{content:""}.fa-cc:before{content:""}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:""}.fa-meanpath:before{content:""}.fa-buysellads:before{content:""}.fa-connectdevelop:before{content:""}.fa-dashcube:before{content:""}.fa-forumbee:before{content:""}.fa-leanpub:before{content:""}.fa-sellsy:before{content:""}.fa-shirtsinbulk:before{content:""}.fa-simplybuilt:before{content:""}.fa-skyatlas:before{content:""}.fa-cart-plus:before{content:""}.fa-cart-arrow-down:before{content:""}.fa-diamond:before{content:""}.fa-ship:before{content:""}.fa-user-secret:before{content:""}.fa-motorcycle:before{content:""}.fa-street-view:before{content:""}.fa-heartbeat:before{content:""}.fa-venus:before{content:""}.fa-mars:before{content:""}.fa-mercury:before{content:""}.fa-intersex:before,.fa-transgender:before{content:""}.fa-transgender-alt:before{content:""}.fa-venus-double:before{content:""}.fa-mars-double:before{content:""}.fa-venus-mars:before{content:""}.fa-mars-stroke:before{content:""}.fa-mars-stroke-v:before{content:""}.fa-mars-stroke-h:before{content:""}.fa-neuter:before{content:""}.fa-genderless:before{content:""}.fa-facebook-official:before{content:""}.fa-pinterest-p:before{content:""}.fa-whatsapp:before{content:""}.fa-server:before{content:""}.fa-user-plus:before{content:""}.fa-user-times:before{content:""}.fa-hotel:before,.fa-bed:before{content:""}.fa-viacoin:before{content:""}.fa-train:before{content:""}.fa-subway:before{content:""}.fa-medium:before{content:""}.fa-yc:before,.fa-y-combinator:before{content:""}.fa-optin-monster:before{content:""}.fa-opencart:before{content:""}.fa-expeditedssl:before{content:""}.fa-battery-4:before,.fa-battery:before,.fa-battery-full:before{content:""}.fa-battery-3:before,.fa-battery-three-quarters:before{content:""}.fa-battery-2:before,.fa-battery-half:before{content:""}.fa-battery-1:before,.fa-battery-quarter:before{content:""}.fa-battery-0:before,.fa-battery-empty:before{content:""}.fa-mouse-pointer:before{content:""}.fa-i-cursor:before{content:""}.fa-object-group:before{content:""}.fa-object-ungroup:before{content:""}.fa-sticky-note:before{content:""}.fa-sticky-note-o:before{content:""}.fa-cc-jcb:before{content:""}.fa-cc-diners-club:before{content:""}.fa-clone:before{content:""}.fa-balance-scale:before{content:""}.fa-hourglass-o:before{content:""}.fa-hourglass-1:before,.fa-hourglass-start:before{content:""}.fa-hourglass-2:before,.fa-hourglass-half:before{content:""}.fa-hourglass-3:before,.fa-hourglass-end:before{content:""}.fa-hourglass:before{content:""}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:""}.fa-hand-stop-o:before,.fa-hand-paper-o:before{content:""}.fa-hand-scissors-o:before{content:""}.fa-hand-lizard-o:before{content:""}.fa-hand-spock-o:before{content:""}.fa-hand-pointer-o:before{content:""}.fa-hand-peace-o:before{content:""}.fa-trademark:before{content:""}.fa-registered:before{content:""}.fa-creative-commons:before{content:""}.fa-gg:before{content:""}.fa-gg-circle:before{content:""}.fa-tripadvisor:before{content:""}.fa-odnoklassniki:before{content:""}.fa-odnoklassniki-square:before{content:""}.fa-get-pocket:before{content:""}.fa-wikipedia-w:before{content:""}.fa-safari:before{content:""}.fa-chrome:before{content:""}.fa-firefox:before{content:""}.fa-opera:before{content:""}.fa-internet-explorer:before{content:""}.fa-tv:before,.fa-television:before{content:""}.fa-contao:before{content:""}.fa-500px:before{content:""}.fa-amazon:before{content:""}.fa-calendar-plus-o:before{content:""}.fa-calendar-minus-o:before{content:""}.fa-calendar-times-o:before{content:""}.fa-calendar-check-o:before{content:""}.fa-industry:before{content:""}.fa-map-pin:before{content:""}.fa-map-signs:before{content:""}.fa-map-o:before{content:""}.fa-map:before{content:""}.fa-commenting:before{content:""}.fa-commenting-o:before{content:""}.fa-houzz:before{content:""}.fa-vimeo:before{content:""}.fa-black-tie:before{content:""}.fa-fonticons:before{content:""}.fa-reddit-alien:before{content:""}.fa-edge:before{content:""}.fa-credit-card-alt:before{content:""}.fa-codiepie:before{content:""}.fa-modx:before{content:""}.fa-fort-awesome:before{content:""}.fa-usb:before{content:""}.fa-product-hunt:before{content:""}.fa-mixcloud:before{content:""}.fa-scribd:before{content:""}.fa-pause-circle:before{content:""}.fa-pause-circle-o:before{content:""}.fa-stop-circle:before{content:""}.fa-stop-circle-o:before{content:""}.fa-shopping-bag:before{content:""}.fa-shopping-basket:before{content:""}.fa-hashtag:before{content:""}.fa-bluetooth:before{content:""}.fa-bluetooth-b:before{content:""}.fa-percent:before{content:""}.fa-gitlab:before{content:""}.fa-wpbeginner:before{content:""}.fa-wpforms:before{content:""}.fa-envira:before{content:""}.fa-universal-access:before{content:""}.fa-wheelchair-alt:before{content:""}.fa-question-circle-o:before{content:""}.fa-blind:before{content:""}.fa-audio-description:before{content:""}.fa-volume-control-phone:before{content:""}.fa-braille:before{content:""}.fa-assistive-listening-systems:before{content:""}.fa-asl-interpreting:before,.fa-american-sign-language-interpreting:before{content:""}.fa-deafness:before,.fa-hard-of-hearing:before,.fa-deaf:before{content:""}.fa-glide:before{content:""}.fa-glide-g:before{content:""}.fa-signing:before,.fa-sign-language:before{content:""}.fa-low-vision:before{content:""}.fa-viadeo:before{content:""}.fa-viadeo-square:before{content:""}.fa-snapchat:before{content:""}.fa-snapchat-ghost:before{content:""}.fa-snapchat-square:before{content:""}.fa-pied-piper:before{content:""}.fa-first-order:before{content:""}.fa-yoast:before{content:""}.fa-themeisle:before{content:""}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:""}.fa-fa:before,.fa-font-awesome:before{content:""}.fa-handshake-o:before{content:""}.fa-envelope-open:before{content:""}.fa-envelope-open-o:before{content:""}.fa-linode:before{content:""}.fa-address-book:before{content:""}.fa-address-book-o:before{content:""}.fa-vcard:before,.fa-address-card:before{content:""}.fa-vcard-o:before,.fa-address-card-o:before{content:""}.fa-user-circle:before{content:""}.fa-user-circle-o:before{content:""}.fa-user-o:before{content:""}.fa-id-badge:before{content:""}.fa-drivers-license:before,.fa-id-card:before{content:""}.fa-drivers-license-o:before,.fa-id-card-o:before{content:""}.fa-quora:before{content:""}.fa-free-code-camp:before{content:""}.fa-telegram:before{content:""}.fa-thermometer-4:before,.fa-thermometer:before,.fa-thermometer-full:before{content:""}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:""}.fa-thermometer-2:before,.fa-thermometer-half:before{content:""}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:""}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:""}.fa-shower:before{content:""}.fa-bathtub:before,.fa-s15:before,.fa-bath:before{content:""}.fa-podcast:before{content:""}.fa-window-maximize:before{content:""}.fa-window-minimize:before{content:""}.fa-window-restore:before{content:""}.fa-times-rectangle:before,.fa-window-close:before{content:""}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:""}.fa-bandcamp:before{content:""}.fa-grav:before{content:""}.fa-etsy:before{content:""}.fa-imdb:before{content:""}.fa-ravelry:before{content:""}.fa-eercast:before{content:""}.fa-microchip:before{content:""}.fa-snowflake-o:before{content:""}.fa-superpowers:before{content:""}.fa-wpexplorer:before{content:""}.fa-meetup:before{content:""}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto} diff --git a/assets/js/builder/Models/Quiz.js b/assets/js/builder/Models/Quiz.js index 9b63b75977..d7d8ff19e9 100644 --- a/assets/js/builder/Models/Quiz.js +++ b/assets/js/builder/Models/Quiz.js @@ -2,7 +2,7 @@ * Quiz Model. * * @since 3.16.0 - * @version [version] + * @version 7.5.0 */ define( [ 'Collections/Questions', @@ -51,7 +51,7 @@ define( [ * * @since 3.16.0 * @since 7.4.0 Added filter for filtering defaults. - * @since [version] Replaced unused `random_answers` property with `random_questions`. + * @since 7.5.0 Replaced unused `random_answers` property with `random_questions`. * * @return {Object} */ diff --git a/assets/js/llms-builder.js b/assets/js/llms-builder.js index fd6dea9a4a..eea455aade 100644 --- a/assets/js/llms-builder.js +++ b/assets/js/llms-builder.js @@ -3386,7 +3386,7 @@ define( 'Schemas/Quiz',[], function() { * Quiz Model. * * @since 3.16.0 - * @version 7.4.0 + * @version 7.5.0 */ define( 'Models/Quiz',[ 'Collections/Questions', @@ -3431,10 +3431,11 @@ define( 'Models/Quiz',[ schema: QuizSchema, /** - * New lesson defaults. + * New quiz defaults. * * @since 3.16.0 * @since 7.4.0 Added filter for filtering defaults. + * @since 7.5.0 Replaced unused `random_answers` property with `random_questions`. * * @return {Object} */ @@ -3448,23 +3449,23 @@ define( 'Models/Quiz',[ status: 'draft', - // editable fields + // editable fields. content: '', allowed_attempts: 5, limit_attempts: 'no', limit_time: 'no', passing_percent: 65, name: '', - random_answers: 'no', + random_questions: 'no', time_limit: 30, show_correct_answer: 'no', questions: [], - // calculated + // calculated. _points: 0, - // display + // display. permalink: '', _show_settings: false, _questions_loaded: false, diff --git a/assets/js/llms-builder.min.js b/assets/js/llms-builder.min.js index 58c158dfc2..26cab95d0e 100644 --- a/assets/js/llms-builder.min.js +++ b/assets/js/llms-builder.min.js @@ -1,5 +1,5 @@ !function(e){var t,i,n;!function(e){function s(e,t){return y.call(e,t)}function o(e,t){var i,n,s,o,l,r,a,c,d,u,h,_,p=t&&t.split("/"),m=v.map,g=m&&m["*"]||{};if(e){for(e=e.split("/"),l=e.length-1,v.nodeIdCompat&&S.test(e[l])&&(e[l]=e[l].replace(S,"")),"."===e[0].charAt(0)&&p&&(_=p.slice(0,p.length-1),e=_.concat(e)),d=0;d0&&(e.splice(d-1,2),d-=2)}e=e.join("/")}if((p||g)&&m){for(i=e.split("/"),d=i.length;d>0;d-=1){if(n=i.slice(0,d).join("/"),p)for(u=p.length;u>0;u-=1)if((s=m[p.slice(0,u).join("/")])&&(s=s[n])){o=s,r=d;break}if(o)break;!a&&g&&g[n]&&(a=g[n],c=d)}!o&&a&&(o=a,r=c),o&&(i.splice(0,r,o),e=i.join("/"))}return e}function l(t,i){return function(){var n=k.call(arguments,0);return"string"!=typeof n[0]&&1===n.length&&n.push(null),p.apply(e,n.concat([t,i]))}}function r(e){return function(t){return o(t,e)}}function a(e){return function(t){f[e]=t}}function c(t){if(s(b,t)){var i=b[t];delete b[t],w[t]=!0,_.apply(e,i)}if(!s(f,t)&&!s(w,t))throw new Error("No "+t);return f[t]}function d(e){var t,i=e?e.indexOf("!"):-1;return i>-1&&(t=e.substring(0,i),e=e.substring(i+1,e.length)),[t,e]}function u(e){return e?d(e):[]}function h(e){return function(){return v&&v.config&&v.config[e]||{}}}var _,p,m,g,f={},b={},v={},w={},y=Object.prototype.hasOwnProperty,k=[].slice,S=/\.js$/;m=function(e,t){var i,n=d(e),s=n[0],l=t[1];return e=n[1],s&&(s=o(s,l),i=c(s)),s?e=i&&i.normalize?i.normalize(e,r(l)):o(e,l):(e=o(e,l),n=d(e),s=n[0],e=n[1],s&&(i=c(s))),{f:s?s+"!"+e:e,n:e,pr:s,p:i}},g={require:function(e){return l(e)},exports:function(e){var t=f[e];return void 0!==t?t:f[e]={}},module:function(e){return{id:e,uri:"",exports:f[e],config:h(e)}}},_=function(t,i,n,o){var r,d,h,_,p,v,y,k=[],S=typeof n;if(o=o||t,v=u(o),"undefined"===S||"function"===S){for(i=!i.length&&n.length?["require","exports","module"]:i,p=0;p3&&void 0!==arguments[3]?arguments[3]:10;if(s(t)&&n(i))if("function"==typeof o)if("number"==typeof l){var r={callback:o,priority:l,namespace:i};if(e[t]){for(var a=e[t].handlers,c=0;cl);)c++;a.splice(c,0,r),(e.__current||[]).forEach(function(e){e.name===t&&e.currentIndex>=c&&e.currentIndex++})}else e[t]={handlers:[r],runs:0};"hookAdded"!==t&&k("hookAdded",t,i,o,l)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},l=function(e,t){return function(i,o){if(s(i)&&(t||n(o))){if(!e[i])return 0;var l=0;if(t)l=e[i].handlers.length,e[i]={runs:e[i].runs,handlers:[]};else for(var r=e[i].handlers,a=r.length-1;a>=0;a--)!function(t){r[t].namespace===o&&(r.splice(t,1),l++,(e.__current||[]).forEach(function(e){e.name===i&&e.currentIndex>=t&&e.currentIndex--}))}(a);return"hookRemoved"!==i&&k("hookRemoved",i,o),l}}},r=function(e){return function(t){return t in e}},a=function(e,t){return function(i){e[i]||(e[i]={handlers:[],runs:0}),e[i].runs++;for(var n=e[i].handlers,s=arguments.length,o=new Array(s>1?s-1:0),l=1;l li, tbody > tr > td":"_listItem_onMousedown","dblclick > li, tbody > tr > td":"_listItem_onDoubleClick",click:"_listBackground_onClick","click ul.collection-view, table.collection-view":"_listBackground_onClick",keydown:"_onKeydown"},spawnMessages:{focus:"focus"},passMessages:{"*":"."},initializationOptions:[{collection:null},{modelView:null},{modelViewOptions:{}},{itemTemplate:null},{itemTemplateFunction:null},{selectable:!0},{clickToSelect:!0},{selectableModelsFilter:null},{visibleModelsFilter:null},{sortableModelsFilter:null},{selectMultiple:!1},{clickToToggle:!1},{processKeyEvents:!0},{sortable:!1},{sortableOptions:null},{reuseModelViews:!0},{detachedRendering:!1},{emptyListCaption:null}],initialize:function(e){t.ViewOptions.add(this,"initializationOptions"),this.setOptions(e),this.collection||(this.collection=new t.Collection),this._hasBeenRendered=!1,this._isBackboneCourierAvailable()&&t.Courier.add(this),this.$el.data("view",this),this.$el.addClass("collection-view collection-list"),this.selectable&&this.$el.addClass("selectable"),this.selectable&&this.processKeyEvents&&this.$el.attr("tabindex",0),this.selectedItems=[],this._updateItemTemplate(),this.collection&&this._registerCollectionEvents(),this.viewManager=new ChildViewContainer},_onOptionsChanged:function(t,i){var n=this,s=!1;e.each(e.keys(t),function(l){var r=t[l],a=i[l];switch(l){case"collection":r!==a&&(n.stopListening(a),n._registerCollectionEvents());break;case"selectMultiple":!r&&n.selectedItems.length>1&&n.setSelectedModel(e.first(n.selectedItems),{by:"cid"});break;case"selectable":!r&&n.selectedItems.length>0&&n.setSelectedModels([]),r&&this.processKeyEvents?n.$el.attr("tabindex",0):n.$el.removeAttr("tabindex",0);break;case"sortable":t.sortable?n._setupSortable():n.$el.sortable("destroy");break;case"selectableModelsFilter":n.reapplyFilter("selectableModels");break;case"sortableOptions":n.$el.sortable("destroy"),n._setupSortable();break;case"sortableModelsFilter":n.reapplyFilter("sortableModels");break;case"visibleModelsFilter":n.reapplyFilter("visibleModels");break;case"itemTemplate":n._updateItemTemplate();break;case"processKeyEvents":r&&this.selectable?n.$el.attr("tabindex",0):n.$el.removeAttr("tabindex",0);break;case"modelView":n.viewManager.each(function(e){n.viewManager.remove(e),e.remove()})}e.contains(o,l)&&(s=!0)}),this._hasBeenRendered&&s&&this.render()},setOption:function(e,t){var i={};i[e]=t,this.setOptions(i)},getSelectedModel:function(t){return this.selectedItems.length?e.first(this.getSelectedModels(t)):null},getSelectedModels:function(t){var n=this;t=e.extend({},{by:"model"},t);var s=t.by,o=[];switch(s){case"id":e.each(this.selectedItems,function(e){o.push(n.collection.get(e).id)});break;case"cid":o=o.concat(this.selectedItems);break;case"offset":var l=0;this._getVisibleItemEls().each(function(){i(this).is(".selected")&&o.push(l),l++});break;case"model":e.each(this.selectedItems,function(e){o.push(n.collection.get(e))});break;case"view":e.each(this.selectedItems,function(e){o.push(n.viewManager.findByModel(n.collection.get(e)))});break;default:throw new Error("Invalid referenceBy option: "+s)}return o},setSelectedModels:function(t,n){if(!e.isArray(t))throw"Invalid parameter value";if(this.selectable||!(t.length>0)){n=e.extend({},{silent:!1,by:"model"},n);var s=n.by,o=[];switch(s){case"cid":o=t;break;case"id":this.collection.each(function(i){e.contains(t,i.id)&&o.push(i.cid)});break;case"model":o=e.pluck(t,"cid");break;case"view":e.each(t,function(e){o.push(e.model.cid)});break;case"offset":var l=0;this._getVisibleItemEls().each(function(){var n=i(this);e.contains(t,l)&&o.push(n.attr("data-model-cid")),l++});break;default:throw new Error("Invalid referenceBy option: "+s)}var r=this.getSelectedModels(),a=e.clone(this.selectedItems);this.selectedItems=this._convertStringsToInts(o),this._validateSelection();var c=this.getSelectedModels();this._containSameElements(a,this.selectedItems)||(this._addSelectedClassToSelectedItems(a),n.silent||(this._isBackboneCourierAvailable()?this.spawn("selectionChanged",{selectedModels:c,oldSelectedModels:r}):this.trigger("selectionChanged",c,r)),this.updateDependentControls())}},setSelectedModel:function(e,t){e||0===e?this.setSelectedModels([e],t):this.setSelectedModels([],t)},getView:function(t,n){switch(n=e.extend({},{by:"model"},n),n.by){case"id":case"cid":var s=this.collection.get(t)||null;return s&&this.viewManager.findByModel(s);case"offset":var o=this._getVisibleItemEls();return i(o.get(t));case"model":return this.viewManager.findByModel(t);default:throw new Error("Invalid referenceBy option: "+referenceBy)}},render:function(){this._hasBeenRendered=!0,this.selectable&&this._saveSelection();var t;t=this._getContainerEl();var i=this.viewManager;this.viewManager=new ChildViewContainer,i.each(function(e){this.reuseModelViews&&this.collection.get(e.model.cid)?e.$el.detach():e.remove()},this),t.empty();var n;this.detachedRendering&&(n=document.createDocumentFragment()),this.collection.each(function(s){var o=i.findByModelCid(s.cid);this.reuseModelViews&&!e.isUndefined(o)||(o=this._createNewModelView(s,this._getModelViewOptions(s))),this._insertAndRenderModelView(o,n||t)},this),this.detachedRendering&&t.append(n),this.sortable&&this._setupSortable(),this._showEmptyListCaptionIfAppropriate(),this._isBackboneCourierAvailable()?this.spawn("render"):this.trigger("render"),this.selectable&&(this._restoreSelection(),this.updateDependentControls()),this.forceRerenderOnNextSortEvent=!1},_showEmptyListCaptionIfAppropriate:function(){if(this._removeEmptyListCaption(),this.emptyListCaption){if(0===this._getVisibleItemEls().length){var t;t=e.isFunction(this.emptyListCaption)?this.emptyListCaption():this.emptyListCaption;var n,s=i(""+t+"");n=this._isRenderedAsList()?s.wrapAll("
  • ").parent().css(l):s.wrapAll("").parent().parent().css(l),this._getContainerEl().append(n)}}},_removeEmptyListCaption:function(){this._isRenderedAsList()?this._getContainerEl().find("> li > var.empty-list-caption").parent().remove():this._getContainerEl().find("> tr > td > var.empty-list-caption").parent().parent().remove()},_insertAndRenderModelView:function(t,i,n){var s=this._wrapModelView(t);if(11===i.nodeType)i.appendChild(s.get(0));else{var o=i.children().length;!e.isUndefined(n)&&n>=0&&no&&(this.forceRerenderOnNextSortEvent=!0),i.append(s))}this.viewManager.add(t),!1===t.render()&&(s.hide(),s.addClass("not-visible"));var l=!1;e.isFunction(this.visibleModelsFilter)&&(l=!this.visibleModelsFilter(t.model)),1===s.children().length?s.toggle(!l):t.$el.toggle(!l),s.toggleClass("not-visible",l),!l&&this.emptyListCaption&&this._removeEmptyListCaption()},updateDependentControls:function(){this._isBackboneCourierAvailable()?this.spawn("updateDependentControls",{selectedModels:this.getSelectedModels()}):this.trigger("updateDependentControls",this.getSelectedModels())},remove:function(){this.viewManager.each(function(e){e.remove()}),t.View.prototype.remove.apply(this,arguments)},reapplyFilter:function(t){var i=this;if(!e.contains(["selectableModels","sortableModels","visibleModels"],t))throw new Error("Invalid filter identifier supplied to reapplyFilter: "+t);switch(t){case"visibleModels":i.viewManager.each(function(e){var t=i.visibleModelsFilter&&!i.visibleModelsFilter.call(i,e.model);e.$el.toggleClass("not-visible",t),i._modelViewHasWrapperLI(e)?e.$el.closest("li").toggleClass("not-visible",t).toggle(!t):e.$el.toggle(!t)}),this._showEmptyListCaptionIfAppropriate();break;case"sortableModels":i.$el.sortable("destroy"),i.viewManager.each(function(e){var t=i.sortableModelsFilter&&!i.sortableModelsFilter.call(i,e.model);e.$el.toggleClass("not-sortable",t),i._modelViewHasWrapperLI(e)&&e.$el.closest("li").toggleClass("not-sortable",t)}),i._setupSortable();break;case"selectableModels":i.viewManager.each(function(e){var t=i.selectableModelsFilter&&!i.selectableModelsFilter.call(i,e.model);e.$el.toggleClass("not-selectable",t),i._modelViewHasWrapperLI(e)&&e.$el.closest("li").toggleClass("not-selectable",t)}),i._validateSelection()}},_removeModelView:function(e){this.selectable&&this._saveSelection(),this.viewManager.remove(e),this._modelViewHasWrapperLI(e)&&e.$el.parent().remove(),e.remove(),this.selectable&&this._restoreSelection(),this._showEmptyListCaptionIfAppropriate()},_validateSelectionAndRender:function(){this._validateSelection(),this.render()},_registerCollectionEvents:function(){this.listenTo(this.collection,"add",function(e){var t;this._hasBeenRendered&&(t=this._createNewModelView(e,this._getModelViewOptions(e)),this._insertAndRenderModelView(t,this._getContainerEl(),this.collection.indexOf(e))),this._isBackboneCourierAvailable()?this.spawn("add",t):this.trigger("add",t)}),this.listenTo(this.collection,"remove",function(e){var t;this._hasBeenRendered&&(t=this.viewManager.findByModelCid(e.cid),this._removeModelView(t)),this._isBackboneCourierAvailable()?this.spawn("remove"):this.trigger("remove")}),this.listenTo(this.collection,"reset",function(){this._hasBeenRendered&&this.render(),this._isBackboneCourierAvailable()?this.spawn("reset"):this.trigger("reset")}),this.listenTo(this.collection,"sort",function(e,t){this._hasBeenRendered&&(!0!==t.add||this.forceRerenderOnNextSortEvent)&&this.render(),this._isBackboneCourierAvailable()?this.spawn("sort"):this.trigger("sort")})},_getContainerEl:function(){if(this._isRenderedAsTable()){var e=this.$el.find("> tbody");if(e.length>0)return e}return this.$el},_getClickedItemId:function(e){var t=null,n=i(e.currentTarget);if(n.closest(".collection-view").get(0)===this.$el.get(0)){var s=n.closest("[data-model-cid]");return s.length>0&&(t=s.attr("data-model-cid"),i.isNumeric(t)&&(t=parseInt(t,10))),t}},_updateItemTemplate:function(){var t;if(this.itemTemplate){if(0===i(this.itemTemplate).length)throw"Could not find item template from selector: "+this.itemTemplate;t=i(this.itemTemplate).html()}else t=this.$(".item-template").html();t&&(this.itemTemplateFunction=e.template(t))},_validateSelection:function(){var t=e.pluck(this.collection.models,"cid");this.selectedItems=e.intersection(t,this.selectedItems),e.isFunction(this.selectableModelsFilter)&&(this.selectedItems=e.filter(this.selectedItems,function(e){return this.selectableModelsFilter.call(this,this.collection.get(e))},this))},_saveSelection:function(){if(!this.selectable)throw"Attempt to save selection on non-selectable list";this.savedSelection={items:e.clone(this.selectedItems),offset:this.getSelectedModel({by:"offset"})}},_restoreSelection:function(){if(!this.savedSelection)throw"Attempt to restore selection but no selection has been saved!";this.setSelectedModels([],{silent:!0}),this.savedSelection.items.length>0&&(this.setSelectedModels(this.savedSelection.items,{by:"cid",silent:!0}),0===this.selectedItems.length&&this.setSelectedModel(this.savedSelection.offset,{by:"offset"}),this.selectedItems.length!==this.savedSelection.items.length&&(this._isBackboneCourierAvailable()?this.spawn("selectionChanged",{selectedModels:this.getSelectedModels(),oldSelectedModels:[]}):this.trigger("selectionChanged",this.getSelectedModels(),[])))},_addSelectedClassToSelectedItems:function(t){e.isUndefined(t)&&(t=[]);var i=t;i=e.without(i,this.selectedItems),e.each(i,function(e){this._getContainerEl().find("[data-model-cid="+e+"]").removeClass("selected"),this._isRenderedAsList()&&this._getContainerEl().find("li[data-model-cid="+e+"] > *").removeClass("selected")},this);var n=this.selectedItems;n=e.without(n,t),e.each(n,function(e){this._getContainerEl().find("[data-model-cid="+e+"]").addClass("selected"),this._isRenderedAsList()&&this._getContainerEl().find("li[data-model-cid="+e+"] > *").addClass("selected")},this)},_reorderCollectionBasedOnHTML:function(){var e=this;this._getContainerEl().children().each(function(){var t=i(this).attr("data-model-cid");if(t){var n=e.collection.get(t);n&&(e.collection.remove(n,{silent:!0}),e.collection.add(n,{silent:!0,sort:!e.collection.comparator}))}}),this._isBackboneCourierAvailable()?this.spawn("reorder"):this.collection.trigger("reorder"),this.collection.comparator&&this.collection.sort()},_getModelViewConstructor:function(e){return this.modelView||s},_getModelViewOptions:function(t){var i=this.modelViewOptions;return e.isFunction(i)&&(i=i(t)),e.extend({model:t},i)},_createNewModelView:function(t,i){var n=this._getModelViewConstructor(t);if(e.isUndefined(n))throw"Could not find modelView constructor for model";var s=new n(i);return s.collectionListView=s.collectionView=this,s},_wrapModelView:function(t){var i,n=this;return this._isRenderedAsTable()?(i=t.$el,t.$el.attr("data-model-cid",t.model.cid)):this._isRenderedAsList()&&(t.$el.is("li")?(i=t.$el,t.$el.attr("data-model-cid",t.model.cid)):i=t.$el.wrapAll("
  • ").parent()),e.isFunction(this.sortableModelsFilter)&&(this.sortableModelsFilter.call(n,t.model)||(i.addClass("not-sortable"),t.$el.addClass("not-selectable"))),e.isFunction(this.selectableModelsFilter)&&(this.selectableModelsFilter.call(n,t.model)||(i.addClass("not-selectable"),t.$el.addClass("not-selectable"))),i},_convertStringsToInts:function(t){return e.map(t,function(t){if(!e.isString(t))return t;var i=parseInt(t,10);return i==t?i:t})},_containSameElements:function(t,i){return t.length==i.length&&e.intersection(t,i).length==t.length},_isRenderedAsTable:function(){return"table"===this.$el.prop("tagName").toLowerCase()},_isRenderedAsList:function(){return!this._isRenderedAsTable()},_modelViewHasWrapperLI:function(e){return this._isRenderedAsList()&&!e.$el.is("li")},_getVisibleItemEls:function(){return this._getContainerEl().find("> [data-model-cid]:not(.not-visible)")},_charCodes:{upArrow:38,downArrow:40},_isBackboneCourierAvailable:function(){return!e.isUndefined(t.Courier)},_setupSortable:function(){var t=e.extend({axis:"y",distance:10,forcePlaceholderSize:!0,items:this._isRenderedAsTable()?"> tbody > tr:not(.not-sortable)":"> li:not(.not-sortable)",start:e.bind(this._sortStart,this),change:e.bind(this._sortChange,this),stop:e.bind(this._sortStop,this),receive:e.bind(this._receive,this),over:e.bind(this._over,this)},e.result(this,"sortableOptions"));this.$el=this.$el.sortable(t)},_sortStart:function(e,t){var i=this.collection.get(t.item.attr("data-model-cid"));this._isBackboneCourierAvailable()?this.spawn("sortStart",{modelBeingSorted:i}):this.trigger("sortStart",i)},_sortChange:function(e,t){var i=this.collection.get(t.item.attr("data-model-cid"));this._isBackboneCourierAvailable()?this.spawn("sortChange",{modelBeingSorted:i}):this.trigger("sortChange",i)},_sortStop:function(e,t){var i=this.collection.get(t.item.attr("data-model-cid")),n=this._getContainerEl(),s=n.children().index(t.item);-1==s&&i&&this.collection.remove(i),i&&(this._reorderCollectionBasedOnHTML(),this.updateDependentControls(),this._isBackboneCourierAvailable()?this.spawn("sortStop",{modelBeingSorted:i,newIndex:s}):this.trigger("sortStop",i,s))},_receive:function(e,t){var i=t.sender,n=i.data("view");if(n&&n.collection){var s=this._getContainerEl().children().index(t.item),o=n.collection.get(t.item.attr("data-model-cid"));n.collection.remove(o),this.collection.add(o,{at:s}),o.collection=this.collection,this.setSelectedModel(o)}},_over:function(e,t){this._getContainerEl().find("> var.empty-list-caption").hide()},_onKeydown:function(e){if(!this.processKeyEvents)return!0;var t=!1;if(1==this.getSelectedModels({by:"offset"}).length){var i=this.getSelectedModel({by:"offset"});e.which===this._charCodes.upArrow&&0!==i?(this.setSelectedModel(i-1,{by:"offset"}),t=!0):e.which===this._charCodes.downArrow&&i!==this.collection.length-1&&(this.setSelectedModel(i+1,{by:"offset"}),t=!0)}return!t},_listItem_onMousedown:function(t){var i=this._getClickedItemId(t);if(i){var n=this.collection.get(i);if(this._isBackboneCourierAvailable()){var s={clickedModel:n,metaKeyPressed:t.ctrlKey||t.metaKey};e.each(["preventDefault","stopPropagation","stopImmediatePropagation"],function(e){s[e]=function(){t[e]()}}),this.spawn("click",s)}else this.trigger("click",n)}if(this.selectable&&this.clickToSelect)if(i){if(e.isFunction(this.selectableModelsFilter)&&!this.selectableModelsFilter.call(this,this.collection.get(i)))return;if(this.selectMultiple&&t.shiftKey){var o=-1;this.selectedItems.length>0&&this.collection.find(function(t){return o++,e.contains(this.selectedItems,t.cid)},this);var l=-1;this.collection.find(function(e){return l++,e.cid==i},this);for(var r=-1==o?l:o,a=Math.min(l,r),c=Math.max(l,r),d=[],u=a;u<=c;u++)d.push(this.collection.at(u).cid);if(this.setSelectedModels(d,{by:"cid"}),document.selection&&document.selection.empty)document.selection.empty();else if(window.getSelection){var h=window.getSelection();h&&h.removeAllRanges&&h.removeAllRanges()}}else(this.selectMultiple||e.contains(this.selectedItems,i))&&(this.clickToToggle||t.metaKey||t.ctrlKey)?e.contains(this.selectedItems,i)?this.setSelectedModels(e.without(this.selectedItems,i),{by:"cid"}):this.setSelectedModels(e.union(this.selectedItems,[i]),{by:"cid"}):this.setSelectedModels([i],{by:"cid"})}else this.setSelectedModels([])},_listItem_onDoubleClick:function(e){var t=this._getClickedItemId(e);if(t){var i=this.collection.get(t);this._isBackboneCourierAvailable()?this.spawn("doubleClick",{clickedModel:i,metaKeyPressed:e.ctrlKey||e.metaKey}):this.trigger("doubleClick",i)}},_listBackground_onClick:function(e){this.selectable&&this.clickToSelect&&i(e.target).is(".collection-view")&&this.setSelectedModels([])}},{setDefaultModelViewConstructor:function(e){s=e}}),t.ViewOptions={},t.ViewOptions.add=function(t,i){e.isUndefined(i)&&(i="options"),t.setOptions=function(t){var s=this,o={},l={},r=e.result(this,i);if(!e.isUndefined(r)){var a=n(r);e.each(a,function(i,n){var r=i.required,a=i.defaultValue;if(r){if((!t||!e.contains(e.keys(t),n))&&e.isUndefined(s[n]))throw new Error('Required option "'+n+'" was not supplied.');if(t&&e.contains(e.keys(t),n)&&e.isUndefined(t[n]))throw new Error('Required option "'+n+'" can not be set to undefined.')}if(t&&n in t&&!e.isUndefined(t[n])){var c=s[n],d=t[n];e.isUndefined(c)||c===d||(l[n]=c,o[n]=d),s[n]=d}else e.isUndefined(s[n])&&(s[n]=a)})}e.keys(o).length>0&&(e.isFunction(s.onOptionsChanged)?s.onOptionsChanged(o,l):e.isFunction(s._onOptionsChanged)&&s._onOptionsChanged(o,l))},t.getOptions=function(){var t=e.result(this,i);if(e.isUndefined(t))return{};var s=n(t),o=e.keys(s);return e.pick(this,o)}},ChildViewContainer=function(e,t){var i=function(e){this._views={},this._indexByModel={},this._indexByCustom={},this._updateLength(),t.each(e,this.add,this)};t.extend(i.prototype,{add:function(e,t){var i=e.cid;this._views[i]=e,e.model&&(this._indexByModel[e.model.cid]=i),t&&(this._indexByCustom[t]=i),this._updateLength()},findByModel:function(e){return this.findByModelCid(e.cid)},findByModelCid:function(e){var t=this._indexByModel[e];return this.findByCid(t)},findByCustom:function(e){var t=this._indexByCustom[e];return this.findByCid(t)},findByIndex:function(e){return t.values(this._views)[e]},findByCid:function(e){return this._views[e]},findIndexByCid:function(e){var i=-1;return t.find(this._views,function(t){if(i++,t.model.cid==e)return t})?i:-1},remove:function(e){var i=e.cid;e.model&&delete this._indexByModel[e.model.cid],t.any(this._indexByCustom,function(e,t){if(e===i)return delete this._indexByCustom[t],!0},this),delete this._views[i],this._updateLength()},call:function(e){this.apply(e,t.tail(arguments))},apply:function(e,i){t.each(this._views,function(n){t.isFunction(n[e])&&n[e].apply(n,i||[])})},_updateLength:function(){this.length=t.size(this._views)}});var n=["forEach","each","map","find","detect","filter","select","reject","every","all","some","any","include","contains","invoke","toArray","first","initial","rest","last","without","isEmpty","pluck"];return t.each(n,function(e){i.prototype[e]=function(){var i=t.values(this._views),n=[i].concat(t.toArray(arguments));return t[e].apply(t,n)}}),i}(0,e),t.CollectionView}),function(){var e=[],t=function(t){_.isEmpty(t._unsavedChanges)?e=_.filter(e,function(e){return t.cid!=e.cid}):_.findWhere(e,{cid:t.cid})||e.push(t)},i=function(t){var i,n=_.rest(arguments),s=function(e,t){return _.isBoolean(t)?t:(_.isString(t)?e[t]:t).apply(e,n)};return _.each(e,function(e){!i&&s(e,e._unsavedConfig[t])&&(i=e._unsavedConfig.prompt)}),i};Backbone.History.prototype.navigate=_.wrap(Backbone.History.prototype.navigate,function(e,t,n){var s=i("unloadRouterPrompt",t,n);s?confirm(s+" \n\nAre you sure you want to leave this page?")&&e.call(this,t,n):e.call(this,t,n)}),window.onbeforeunload=function(e){return i("unloadWindowPrompt",e)},_.extend(Backbone.Model.prototype,{unsaved:{},_trackingChanges:!1,_originalAttrs:{},_unsavedChanges:{},startTracking:function(){return this._unsavedConfig=_.extend({},{prompt:"You have unsaved changes!",unloadRouterPrompt:!1,unloadWindowPrompt:!1},this.unsaved||{}),this._trackingChanges=!0,this._resetTracking(),this._triggerUnsavedChanges(),this},stopTracking:function(){return this._trackingChanges=!1,this._originalAttrs={},this._unsavedChanges={},this._triggerUnsavedChanges(),this},restartTracking:function(){return this._resetTracking(),this._triggerUnsavedChanges(),this},resetAttributes:function(){if(this._trackingChanges)return this.attributes=this._originalAttrs,this._resetTracking(),this._triggerUnsavedChanges(),this},unsavedAttributes:function(e){if(!e)return!_.isEmpty(this._unsavedChanges)&&_.clone(this._unsavedChanges);var t,i=!1,n=this._unsavedChanges;for(var s in e)_.isEqual(n[s],t=e[s])||((i||(i={}))[s]=t);return i},_resetTracking:function(){this._originalAttrs=_.deepClone(this.attributes),this._unsavedChanges={}},_triggerUnsavedChanges:function(){this.trigger("unsavedChanges",!_.isEmpty(this._unsavedChanges),_.clone(this._unsavedChanges)),this.unsaved&&t(this)}}),Backbone.Model.prototype.set=_.wrap(Backbone.Model.prototype.set,function(e,t,i,n){var s,o;return null==t?this:("object"==typeof t?(s=t,n=i):(s={})[t]=i,n||(n={}),o=e.call(this,s,n),this._trackingChanges&&!n.silent&&(_.each(s,_.bind(function(e,t){_.isEqual(this._originalAttrs[t],e)?delete this._unsavedChanges[t]:this._unsavedChanges[t]=e},this)),this._triggerUnsavedChanges()),o)}),Backbone.sync=_.wrap(Backbone.sync,function(e,t,i,n){return n||(n={}),"update"==t&&(n.success=_.wrap(n.success,_.bind(function(e,t,n,s){var o;return e&&(o=e.call(this,t,n,s)),i._trackingChanges&&(i._resetTracking(),i._triggerUnsavedChanges()),o},this))),e(t,i,n)})}(),n("vendor/backbone.trackit",function(){}),n("Models/Image",[],function(){return Backbone.Model.extend({defaults:{enabled:"no",id:"",size:"full",src:""},initialize:function(){this.startTracking()}})}),n("Models/_Relationships",[],function(){return{relationship_defaults:{parent:{},children:{}},relationships:{},init_relationships:function(e){var t=this.get_relationships();t.parent&&e&&e.parent&&this.set_parent(e.parent),_.each(t.children,function(e,t){if(!e.conditional||!0===e.conditional(this)){var i,n=this.get(t);e.lookup?i=e.lookup(n):"model"===e.type?i=window.llms_builder.construct.get_model(e.class,n):"collection"===e.type&&(i=window.llms_builder.construct.get_collection(e.class,n)),this.set(t,i), -"model"===e.type?this._maybe_set_parent_reference(i):"collection"===e.type&&(i.parent=this,i.each(function(e){this._maybe_set_parent_reference(e)},this))}},this)},get_child_props:function(){var e=[];return _.each(this.get_relationships().children,function(t,i){t.conditional&&!0!==t.conditional(this)||e.push(i)},this),e},get_parent:function(){var e=this.get_relationships();return!!e.parent&&e.parent.reference},get_relationships:function(){return e.extend(!0,this.relationships,this.relationship_defaults)},set_parent:function(e){this.relationships.parent.reference=e},_maybe_set_parent_reference:function(e){if(e&&e.get_relationships){var t=e.get_relationships();t.parent&&t.parent.model===this.get("type")&&e.set_parent(this)}}}}),n("Models/QuestionChoice",["Models/Image","Models/_Relationships"],function(e,t){return Backbone.Model.extend(_.defaults({relationships:{parent:{model:"llms_question",type:"model"},children:{choice:{conditional:function(e){return"image"===e.get("choice_type")},class:"Image",model:"image",type:"model"}}},defaults:function(){return{id:_.uniqueId("temp_"),choice:"",choice_type:"text",correct:!1,marker:"A",question_id:"",type:"choice"}},initialize:function(e,t){this.startTracking(),this.init_relationships(t)},get_parent:function(){return this.collection.parent},get_trash_id:function(){return this.get("question_id")+":"+this.get("id")},is_selectable:function(){return this.get_parent().get("question_type").get_choice_selectable()}},t))}),n("Collections/QuestionChoices",["Models/QuestionChoice"],function(e){return Backbone.Collection.extend({model:e,initialize:function(){this.on("reorder",this.update_order),this.on("add",this.update_order),this.on("remove",this.update_order),this.on("add",this.update_correct),this.on("remove",this.update_correct),this.on("correct-update",this.update_correct)},count_correct:function(){return _.size(this.get_correct())},get_correct:function(){return this.filter(function(e){return e.get("correct")})},update_correct:function(e){if(this.parent.get("question_type").get_choice_selectable()){var t=this.without(e),i=this.parent;if("no"===i.get("multi_choices")&&_.each(t,function(e){e.set("correct",!1)}),0===this.count_correct()&&i.get("points")>0){var n=1===this.size()?this.models:t;_.first(n).set("correct",!0)}}},update_order:function(){var e=this,t=this.parent;this.each(function(i){i.set("marker",t.get("question_type").get_choice_markers()[e.indexOf(i)])})}})}),n("Models/QuestionType",[],function(){return Backbone.Model.extend({defaults:function(){return{choices:!1,clarifications:!0,default_choices:[],description:!0,icon:"question",id:"generic",image:!0,keywords:[],name:"Generic",placeholder:"",points:!0,video:!0}},get_keywords:function(){var e=this.get("name");return[e].concat(this.get("keywords")).concat(e.split(" "))},get_choice_markers:function(){return this._get_choice_option("markers")},get_choice_selectable:function(){return this._get_choice_option("selectable")},get_choice_type:function(){return this._get_choice_option("type")},get_min_choices:function(){return this._get_choice_option("min")},get_max_choices:function(){return this._get_choice_option("max")},get_multi_choices:function(){return!!this.get("choices")&&this._get_choice_option("multi")},_get_choice_option:function(e){var t=this.get("choices");return!(!t||!t[e])&&t[e]}})}),n("Models/_Utilities",[],function(){return{fields:[],set:function(e,t){if("string"==typeof e){const i=e.match(/(.*?)\[(.*?)\]/);if(i&&3===i.length){const n=i[1],s=Backbone.Model.prototype.get.call(this,n);var o=void 0!==s?s:{};o[i[2]]=t,arguments[0]=n,arguments[1]=o}}Backbone.Model.prototype.set.apply(this,arguments)},get:function(e){const t=e.match(/(.*?)\[(.*?)\]/);if(t&&3===t.length){const i=Backbone.Model.prototype.get.call(this,t[1]);if(i&&void 0!==i[t[2]])return i[t[2]]}return Backbone.Model.prototype.get.call(this,e)},get_edit_post_link:function(){return this.has_temp_id()?"":window.llms_builder.admin_url+"post.php?post="+this.get("id")+"&action=edit"},get_settings_fields:function(){var e=this.schema||{};return window.llms_builder.schemas.get(e,this.get("type").replace("llms_",""),this)},has_temp_id:function(){return!_.isNumber(this.get("id"))&&0===this.get("id").indexOf("temp_")},init_custom_schema:function(){var e=_.filter(this.get_settings_fields(),function(e){return e.custom});_.each(e,function(e){_.each(_.flatten(e.fields),function(e){var t=[e.attribute],i=this.get("custom");e.switch_attribute&&t.push(e.switch_attribute),_.each(t,function(t){var n=e.attribute_prefix?e.attribute_prefix+t:t;i&&i[n]&&this.set(t,i[n][0])},this)},this)},this)}}}),n("Models/Question",["Models/Image","Collections/Questions","Collections/QuestionChoices","Models/QuestionType","Models/_Relationships","Models/_Utilities"],function(e,t,i,n,s,o){return Backbone.Model.extend(_.defaults({relationships:{parent:{model:"llms_quiz",type:"model"},children:{choices:{class:"QuestionChoices",model:"choice",type:"collection"},image:{class:"Image",model:"image",type:"model"},questions:{class:"Questions",conditional:function(e){var t=e.get("question_type");return"group"===(_.isString(t)?t:t.get("id"))},model:"llms_question",type:"collection"},question_type:{class:"QuestionType",lookup:function(e){return _.isString(e)?window.llms_builder.questions.get(e):e},model:"question_type",type:"model"}}},defaults:function(){return{id:_.uniqueId("temp_"),choices:[],content:"",description_enabled:"no",image:{},multi_choices:"no",menu_order:1,points:1,question_type:"generic",questions:[],parent_id:"",title:"",type:"llms_question",video_enabled:"no",video_src:"",_expanded:!1}},initialize:function(e,t){var i=this;this.startTracking(),this.init_relationships(t),!1!==this.get("question_type").choices&&(this._ensure_min_choices(),this.listenTo(this.get("choices"),"remove",function(){setTimeout(function(){i._ensure_min_choices()},0)})),this.get("question_type").get("points")||this.set("points",0),_.delay(function(e){e.on("change:points",e.get_parent().update_points,e.get_parent())},1,this)},add_choice:function(e,t){var i=this.get("question_type").get_max_choices();if(!(this.get("choices").size()>=i)){e=e||{},t=t||{},e.choice_type=this.get("question_type").get_choice_type(),e.question_id=this.get("id"),t.parent=this;var n=this.get("choices").add(e,t);Backbone.pubSub.trigger("question-add-choice",n,this)}},before_save:function(e,t){return"full"===t&&(e.question_type=this.get("question_type").get("id")),e},get_parent:function(){var e=this.get_relationships();if(e.parent){if(this.collection&&this.collection.parent)return this.collection.parent;if(e.parent.reference)return e.parent.reference}return!1},get_l10n_type:function(e){return e?LLMS.l10n.translate("questions"):LLMS.l10n.translate("question")},get_type_index:function(){var e,t=this.get("question_type").get("id");return e=this.collection.filter(function(e){var i=e.get("question_type").get("id");return"content"!==t?"content"!==i:"content"===i}),e.indexOf(this)},get_type_iterator:function(){var e=this.get_type_index();if(-1===e)return"";if("content"===this.get("question_type").get("id")){return"ABCDEFGHIJKLMNOPQRSTUVWXYZ".split("")[e]}return e+1},get_qid:function(){var e=this.get_parent_question(),t="";return e&&(t=e.get_qid()+"."),t+this.get_type_iterator()},get_parent_question:function(){return!!this.is_in_group()&&this.collection.parent},get_parent_quiz:function(){return this.get_parent()},get_points:function(){return this.get("question_type").get("points")?this.get("points"):0},get_points_percentage:function(){var e=this.get_parent().get("_points"),t=this.get("points");return 0===e?"0%":(t/e*100).toFixed(2)+"%"},is_in_group:function(){return"question"===this.collection.parent.get("type")},_ensure_min_choices:function(){for(var e=this.get("choices");e.size()=0)return this.collection.at(i);if(t){if("next"===e)return this.collection.first();if("prev"===e)return this.collection.last()}return!1}},t))}),n("Collections/Sections",["Models/Section"],function(e){return Backbone.Collection.extend({model:e,initialize:function(){this.on("reorder",this.update_order),this.on("add",this.update_order),this.on("remove",this.update_order)},update_order:function(){var e=this;this.each(function(t){t.set("order",e.indexOf(t)+1)})}})}),n("Collections/loader",["Collections/Lessons","Collections/QuestionChoices","Collections/Questions","Collections/QuestionTypes","Collections/Sections"],function(e,t,i,n,s){return{Lessons:e,QuestionChoices:t,Questions:i,QuestionTypes:n,Sections:s}}),n("Models/Abstract",["Models/_Relationships","Models/_Utilities"],function(e,t){return Backbone.Model.extend(_.defaults({},e,t))}),n("Models/Course",["Collections/Sections","Models/_Relationships","Models/_Utilities"],function(e,t,i){return Backbone.Model.extend(_.defaults({relationships:{children:{sections:{class:"Sections",model:"section",type:"collection"}}},defaults:function(){return{edit_url:"",sections:[],title:"New Course",type:"course",view_url:""}},initialize:function(){this.startTracking(),this.init_relationships(),Backbone.pubSub.on("add-new-section",this.add_section,this),Backbone.pubSub.on("add-new-lesson",this.add_lesson,this),Backbone.pubSub.on("lesson-search-select",this.add_existing_lesson,this)},add_existing_lesson:function(e){var t=e.data;"clone"===e.action?(delete t.id,t.quiz&&(t.quiz=_.prepareQuizObjectForCloning(t.quiz),t.quiz._questions_loaded=!0),window.llms_builder.assignments&&t.assignment&&(t.assignment=_.prepareAssignmentObjectForCloning(t.assignment))):t._forceSync=!0,delete t.order,delete t.parent_course,delete t.parent_section,t=_.prepareExistingPostObjectDataForAddingOrCloning(t),t=window.llms.hooks.applyFilters("llms_adding_existing_lesson_data",t,e.action,this),this.add_lesson(t)},add_lesson:function(e){e=e||{};var t,i={};e.parent_section?t=this.get("sections").get(e.parent_section):(t=this.get_selected_section())||(t=this.get("sections").last()),e._selected=!0,e.parent_course=this.get("id");var n=t.add_lesson(e,i);return Backbone.pubSub.trigger("new-lesson-added",n),t.set("_expanded",!0),n},add_section:function(e){e=e||{};var t=this.get("sections"),i={},n=this.get_selected_section();n&&(i.at=t.indexOf(n)+1),t.add(e,i)},get_selected_section:function(){return this.get("sections").find(function(e){return e.get("_selected")})},get_total_points:function(){var e=0;return this.get("sections").each(function(t){t.get("lessons").each(function(t){var i=t.get("points");_.isNumber(i)||(i=0),e+=1*i})}),e}},t,i))}),n("Models/loader",["Models/Abstract","Models/Course","Models/Image","Models/Lesson","Models/Question","Models/QuestionChoice","Models/QuestionType","Models/Quiz","Models/Section"],function(e,t,i,n,s,o,l,r,a){return{Abstract:e,Course:t,Image:i,Lesson:n,Question:s,QuestionChoice:o,QuestionType:l,Quiz:r,Section:a}}),n("Views/_Detachable",[],function(){return{events:{'click a[href="#llms-detach-model"]':"detach_model"},detach_model:function(e){e&&(e.preventDefault(),e.stopPropagation());var t=LLMS.l10n.replace("Are you sure you want to detach this %s?",{"%s":this.model.get_l10n_type()});window.confirm(t)&&(this.model.collection&&this.model.collection.remove(this.model),Backbone.pubSub.trigger("model-detached",this.model),this.trigger("model-trashed",this.model))}}}),n("Views/_Editable",[],function(){return{media_lib:null,events:{"click .llms-add-image":"open_media_lib",'click a[href="#llms-edit-slug"]':"make_slug_editable",'click a[href="#llms-remove-image"]':"remove_image","change .llms-editable-select select":"on_select",'change .llms-switch input[type="checkbox"]':"toggle_switch","change .llms-editable-radio input":"on_radio_select","focusin .llms-input":"on_focus","focusout .llms-input":"on_blur","keydown .llms-input":"on_keydown",'input .llms-input[type="number"]':"on_blur","paste .llms-input[data-formatting]":"on_paste"},get_allowed_tags:function(e){return e.attr("data-formatting")?_.map(e.attr("data-formatting").split(","),function(e){return e.trim()}):["b","i","u","strong","em"]},get_content:function(e){return"INPUT"===e[0].tagName?e.val():e.attr("data-formatting")||e.hasClass("ql-editor")?_.stripFormatting(e.html(),this.get_allowed_tags(e)):e.text()},has_changed:function(t){var i=e(t.target);return i.attr("data-original-content")!==this.get_content(i)},is_valid:function(t){var i=this,n=e(t.target),s=this.get_content(n),o=n.attr("data-type");if((n.attr("required")||n.attr("data-required"))&&s.length<1)return!1;if("url"===o||"video"===o){if(!this._validate_url(this.get_content(n)))return!1}else"permalink"===o&&LLMS.Ajax.call({data:{action:"llms_builder",action_type:"get_permalink",course_id:window.llms_builder.CourseModel.get("id"),id:i.model.get("id"),title:i.model.get("title"),slug:s},beforeSend:function(){LLMS.Spinner.start(n.closest(".llms-editable-toggle-group"),"small")},success:function(e){e.permalink&&e.slug&&(i.model.set("permalink",e.permalink),i.model.set("name",e.slug),i.render())}});return!0},init_datepickers:function(){this.$el.find(".llms-editable-date input").each(function(){e(this).datetimepicker({format:e(this).attr("data-date-format")||"Y-m-d h:i A",datepicker:void 0===e(this).attr("data-date-datepicker")||"true"==e(this).attr("data-date-datepicker"),timepicker:void 0===e(this).attr("data-date-timepicker")||"true"==e(this).attr("data-date-timepicker"),onClose:function(e,t){t.blur()}})})},init_formatting_els:function(){var t=this;this.$el.find(".llms-input-formatting[data-formatting]").each(function(){var i=e(this).attr("data-formatting").split(","),n=e(this).attr("data-attribute"),s=new Quill(this,{modules:{toolbar:[i],keyboard:{bindings:{tab:{key:9,handler:function(e,t){return!0}},13:{key:13,handler:function(e,t){return s.root.blur(),!1}}}}},placeholder:e(this).attr("data-placeholder"),theme:"bubble"});s.on("text-change",function(i,o,l){t.model.set(n,t.get_content(e(s.root)))}),Backbone.pubSub.trigger("formatting-ed-init",s,e(this),t)})},init_selects:function(){this.$el.find(".llms-editable-select select").llmsSelect2({width:"100%"}).trigger("change")},on_blur:function(t){t.stopPropagation(),this.model.set("_has_focus",!1,{silent:!0});var i=this;e(t.target);this.has_changed(t)&&(i.is_valid(t)?this.save_edits(t):i.revert_edits(t))},on_focus:function(e){e.stopPropagation(),this.model.set("_has_focus",!0,{silent:!0})},on_paste:function(e){e.preventDefault(),e.stopPropagation();var t=(e.originalEvent||e).clipboardData.getData("text/plain");window.document.execCommand("insertText",!1,t)},on_select:function(t){var i,n=e(t.target),s=n.attr("multiple"),o=n.attr("name"),l=n.find("option:selected");s?(i=[],i=l.map(function(){return this.value}).get()):i=l[0].value,this.model.set(o,i)},on_radio_select:function(t){var i=e(t.target),n=i.attr("name"),s=i.val();this.model.set(n,s)},on_keydown:function(e){e.stopPropagation();var t=e.which||e.keyCode,i=e.shiftKey;switch(t){case 13:i||(e.preventDefault(),e.target.blur());break;case 27:e.preventDefault(),this.revert_edits(e),e.target.blur()}},open_media_lib:function(t){t.stopPropagation();var i=this,n=e(t.currentTarget);i.media_lib?i.media_lib.uploader.uploader.param("post_id"):(i.media_lib=wp.media.frames.file_frame=wp.media({title:LLMS.l10n.translate("Select an image"),button:{text:LLMS.l10n.translate("Use this image")},multiple:!1}),i.media_lib.on("select",function(){var e,t=n.attr("data-image-size"),s=i.media_lib.state().get("selection").first().toJSON(),o=i.model.get(n.attr("data-attribute"));e=t&&s.sizes[t]?s.sizes[t].url:s.url,o.set({id:s.id,src:e})})),i.media_lib.open()},remove_image:function(t){t.preventDefault(),this.model.get(e(t.currentTarget).attr("data-attribute")).set({id:"",src:""})},revert_edits:function(t){var i=e(t.target),n=i.attr("data-original-content");i.html(n)},save_edits:function(t){var i=e(t.target),n=this.get_content(i);this.model.set(i.attr("data-attribute"),n)},toggle_switch:function(t){t.stopPropagation();var i,n=e(t.target),s=n.attr("name"),o=n.attr("data-rerender");if(i=n.is(":checked")?n.attr("data-on")?n.attr("data-on"):"yes":n.attr("data-off")?n.attr("data-off"):"no",-1!==s.indexOf(".")){var l=s.split(".");"parent"===l[0]?this.model.get_parent().set(l[1],i):this.model.get(l[0]).set(l[1],i)}else this.model.set(s,i);if(this.trigger(s.replace(".","-")+"_toggle",i),!o||"yes"===o){var r=this;setTimeout(function(){r.render()},100)}},init_editor:function(t,i){i=i||{};var n=_.getEditor();n.remove(t),n.initialize(t,e.extend(!0,n.getDefaultSettings(),{mediaButtons:!0,tinymce:{toolbar1:"bold,italic,strikethrough,bullist,numlist,blockquote,hr,alignleft,aligncenter,alignright,link,unlink,wp_adv",toolbar2:"formatselect,underline,alignjustify,forecolor,pastetext,removeformat,charmap,outdent,indent,undo,redo,wp_help",setup:_.bind(this.on_editor_ready,this)}},i))},make_slug_editable:function(t){var i=e(t.currentTarget),n=i.prevAll("a"),s=i.prev("input.permalink"),o=n.attr("href"),l=s.val(),r=o.replace(l,"");i.hide(),n.css({color:"#999","pointer-events":"none","text-decoration":"none"}),n.text(r.substring(0,r.length-1)),s.show().focus()},on_editor_ready:function(t){var i=this,n=e("#"+t.id),s=n.closest(".llms-editable-editor"),o=s.find(".llms-label"),l=n.attr("data-attribute");o.length&&o.prependTo(s.find(".wp-editor-tools")),t.on("change",function(e){i.model.set(l,_.getEditor().getContent(t.id))}),n.on("input",function(e){i.model.set(l,n.val())}),s.on("click",".quicktags-toolbar .ed_button",function(){setTimeout(function(){n.trigger("input")},10)})},_validate_url:function(e){var t=document.createElement("a");return t.href=e,t.host&&t.host!==window.location.host}}}),n("Views/_Receivable",[],function(){return{_receive:function(e,t){if(t.sender.hasClass("ui-draggable")){var i=this._getContainerEl().children().index(t.helper);return t.helper.remove(),void this.collection.add({},{at:i})}var n=t.sender,s=n.data("view");if(s&&s.collection){var o=this._getContainerEl().children().index(t.item),l=s.collection.get(t.item.attr("data-model-cid")) +"model"===e.type?this._maybe_set_parent_reference(i):"collection"===e.type&&(i.parent=this,i.each(function(e){this._maybe_set_parent_reference(e)},this))}},this)},get_child_props:function(){var e=[];return _.each(this.get_relationships().children,function(t,i){t.conditional&&!0!==t.conditional(this)||e.push(i)},this),e},get_parent:function(){var e=this.get_relationships();return!!e.parent&&e.parent.reference},get_relationships:function(){return e.extend(!0,this.relationships,this.relationship_defaults)},set_parent:function(e){this.relationships.parent.reference=e},_maybe_set_parent_reference:function(e){if(e&&e.get_relationships){var t=e.get_relationships();t.parent&&t.parent.model===this.get("type")&&e.set_parent(this)}}}}),n("Models/QuestionChoice",["Models/Image","Models/_Relationships"],function(e,t){return Backbone.Model.extend(_.defaults({relationships:{parent:{model:"llms_question",type:"model"},children:{choice:{conditional:function(e){return"image"===e.get("choice_type")},class:"Image",model:"image",type:"model"}}},defaults:function(){return{id:_.uniqueId("temp_"),choice:"",choice_type:"text",correct:!1,marker:"A",question_id:"",type:"choice"}},initialize:function(e,t){this.startTracking(),this.init_relationships(t)},get_parent:function(){return this.collection.parent},get_trash_id:function(){return this.get("question_id")+":"+this.get("id")},is_selectable:function(){return this.get_parent().get("question_type").get_choice_selectable()}},t))}),n("Collections/QuestionChoices",["Models/QuestionChoice"],function(e){return Backbone.Collection.extend({model:e,initialize:function(){this.on("reorder",this.update_order),this.on("add",this.update_order),this.on("remove",this.update_order),this.on("add",this.update_correct),this.on("remove",this.update_correct),this.on("correct-update",this.update_correct)},count_correct:function(){return _.size(this.get_correct())},get_correct:function(){return this.filter(function(e){return e.get("correct")})},update_correct:function(e){if(this.parent.get("question_type").get_choice_selectable()){var t=this.without(e),i=this.parent;if("no"===i.get("multi_choices")&&_.each(t,function(e){e.set("correct",!1)}),0===this.count_correct()&&i.get("points")>0){var n=1===this.size()?this.models:t;_.first(n).set("correct",!0)}}},update_order:function(){var e=this,t=this.parent;this.each(function(i){i.set("marker",t.get("question_type").get_choice_markers()[e.indexOf(i)])})}})}),n("Models/QuestionType",[],function(){return Backbone.Model.extend({defaults:function(){return{choices:!1,clarifications:!0,default_choices:[],description:!0,icon:"question",id:"generic",image:!0,keywords:[],name:"Generic",placeholder:"",points:!0,video:!0}},get_keywords:function(){var e=this.get("name");return[e].concat(this.get("keywords")).concat(e.split(" "))},get_choice_markers:function(){return this._get_choice_option("markers")},get_choice_selectable:function(){return this._get_choice_option("selectable")},get_choice_type:function(){return this._get_choice_option("type")},get_min_choices:function(){return this._get_choice_option("min")},get_max_choices:function(){return this._get_choice_option("max")},get_multi_choices:function(){return!!this.get("choices")&&this._get_choice_option("multi")},_get_choice_option:function(e){var t=this.get("choices");return!(!t||!t[e])&&t[e]}})}),n("Models/_Utilities",[],function(){return{fields:[],set:function(e,t){if("string"==typeof e){const i=e.match(/(.*?)\[(.*?)\]/);if(i&&3===i.length){const n=i[1],s=Backbone.Model.prototype.get.call(this,n);var o=void 0!==s?s:{};o[i[2]]=t,arguments[0]=n,arguments[1]=o}}Backbone.Model.prototype.set.apply(this,arguments)},get:function(e){const t=e.match(/(.*?)\[(.*?)\]/);if(t&&3===t.length){const i=Backbone.Model.prototype.get.call(this,t[1]);if(i&&void 0!==i[t[2]])return i[t[2]]}return Backbone.Model.prototype.get.call(this,e)},get_edit_post_link:function(){return this.has_temp_id()?"":window.llms_builder.admin_url+"post.php?post="+this.get("id")+"&action=edit"},get_settings_fields:function(){var e=this.schema||{};return window.llms_builder.schemas.get(e,this.get("type").replace("llms_",""),this)},has_temp_id:function(){return!_.isNumber(this.get("id"))&&0===this.get("id").indexOf("temp_")},init_custom_schema:function(){var e=_.filter(this.get_settings_fields(),function(e){return e.custom});_.each(e,function(e){_.each(_.flatten(e.fields),function(e){var t=[e.attribute],i=this.get("custom");e.switch_attribute&&t.push(e.switch_attribute),_.each(t,function(t){var n=e.attribute_prefix?e.attribute_prefix+t:t;i&&i[n]&&this.set(t,i[n][0])},this)},this)},this)}}}),n("Models/Question",["Models/Image","Collections/Questions","Collections/QuestionChoices","Models/QuestionType","Models/_Relationships","Models/_Utilities"],function(e,t,i,n,s,o){return Backbone.Model.extend(_.defaults({relationships:{parent:{model:"llms_quiz",type:"model"},children:{choices:{class:"QuestionChoices",model:"choice",type:"collection"},image:{class:"Image",model:"image",type:"model"},questions:{class:"Questions",conditional:function(e){var t=e.get("question_type");return"group"===(_.isString(t)?t:t.get("id"))},model:"llms_question",type:"collection"},question_type:{class:"QuestionType",lookup:function(e){return _.isString(e)?window.llms_builder.questions.get(e):e},model:"question_type",type:"model"}}},defaults:function(){return{id:_.uniqueId("temp_"),choices:[],content:"",description_enabled:"no",image:{},multi_choices:"no",menu_order:1,points:1,question_type:"generic",questions:[],parent_id:"",title:"",type:"llms_question",video_enabled:"no",video_src:"",_expanded:!1}},initialize:function(e,t){var i=this;this.startTracking(),this.init_relationships(t),!1!==this.get("question_type").choices&&(this._ensure_min_choices(),this.listenTo(this.get("choices"),"remove",function(){setTimeout(function(){i._ensure_min_choices()},0)})),this.get("question_type").get("points")||this.set("points",0),_.delay(function(e){e.on("change:points",e.get_parent().update_points,e.get_parent())},1,this)},add_choice:function(e,t){var i=this.get("question_type").get_max_choices();if(!(this.get("choices").size()>=i)){e=e||{},t=t||{},e.choice_type=this.get("question_type").get_choice_type(),e.question_id=this.get("id"),t.parent=this;var n=this.get("choices").add(e,t);Backbone.pubSub.trigger("question-add-choice",n,this)}},before_save:function(e,t){return"full"===t&&(e.question_type=this.get("question_type").get("id")),e},get_parent:function(){var e=this.get_relationships();if(e.parent){if(this.collection&&this.collection.parent)return this.collection.parent;if(e.parent.reference)return e.parent.reference}return!1},get_l10n_type:function(e){return e?LLMS.l10n.translate("questions"):LLMS.l10n.translate("question")},get_type_index:function(){var e,t=this.get("question_type").get("id");return e=this.collection.filter(function(e){var i=e.get("question_type").get("id");return"content"!==t?"content"!==i:"content"===i}),e.indexOf(this)},get_type_iterator:function(){var e=this.get_type_index();if(-1===e)return"";if("content"===this.get("question_type").get("id")){return"ABCDEFGHIJKLMNOPQRSTUVWXYZ".split("")[e]}return e+1},get_qid:function(){var e=this.get_parent_question(),t="";return e&&(t=e.get_qid()+"."),t+this.get_type_iterator()},get_parent_question:function(){return!!this.is_in_group()&&this.collection.parent},get_parent_quiz:function(){return this.get_parent()},get_points:function(){return this.get("question_type").get("points")?this.get("points"):0},get_points_percentage:function(){var e=this.get_parent().get("_points"),t=this.get("points");return 0===e?"0%":(t/e*100).toFixed(2)+"%"},is_in_group:function(){return"question"===this.collection.parent.get("type")},_ensure_min_choices:function(){for(var e=this.get("choices");e.size()=0)return this.collection.at(i);if(t){if("next"===e)return this.collection.first();if("prev"===e)return this.collection.last()}return!1}},t))}),n("Collections/Sections",["Models/Section"],function(e){return Backbone.Collection.extend({model:e,initialize:function(){this.on("reorder",this.update_order),this.on("add",this.update_order),this.on("remove",this.update_order)},update_order:function(){var e=this;this.each(function(t){t.set("order",e.indexOf(t)+1)})}})}),n("Collections/loader",["Collections/Lessons","Collections/QuestionChoices","Collections/Questions","Collections/QuestionTypes","Collections/Sections"],function(e,t,i,n,s){return{Lessons:e,QuestionChoices:t,Questions:i,QuestionTypes:n,Sections:s}}),n("Models/Abstract",["Models/_Relationships","Models/_Utilities"],function(e,t){return Backbone.Model.extend(_.defaults({},e,t))}),n("Models/Course",["Collections/Sections","Models/_Relationships","Models/_Utilities"],function(e,t,i){return Backbone.Model.extend(_.defaults({relationships:{children:{sections:{class:"Sections",model:"section",type:"collection"}}},defaults:function(){return{edit_url:"",sections:[],title:"New Course",type:"course",view_url:""}},initialize:function(){this.startTracking(),this.init_relationships(),Backbone.pubSub.on("add-new-section",this.add_section,this),Backbone.pubSub.on("add-new-lesson",this.add_lesson,this),Backbone.pubSub.on("lesson-search-select",this.add_existing_lesson,this)},add_existing_lesson:function(e){var t=e.data;"clone"===e.action?(delete t.id,t.quiz&&(t.quiz=_.prepareQuizObjectForCloning(t.quiz),t.quiz._questions_loaded=!0),window.llms_builder.assignments&&t.assignment&&(t.assignment=_.prepareAssignmentObjectForCloning(t.assignment))):t._forceSync=!0,delete t.order,delete t.parent_course,delete t.parent_section,t=_.prepareExistingPostObjectDataForAddingOrCloning(t),t=window.llms.hooks.applyFilters("llms_adding_existing_lesson_data",t,e.action,this),this.add_lesson(t)},add_lesson:function(e){e=e||{};var t,i={};e.parent_section?t=this.get("sections").get(e.parent_section):(t=this.get_selected_section())||(t=this.get("sections").last()),e._selected=!0,e.parent_course=this.get("id");var n=t.add_lesson(e,i);return Backbone.pubSub.trigger("new-lesson-added",n),t.set("_expanded",!0),n},add_section:function(e){e=e||{};var t=this.get("sections"),i={},n=this.get_selected_section();n&&(i.at=t.indexOf(n)+1),t.add(e,i)},get_selected_section:function(){return this.get("sections").find(function(e){return e.get("_selected")})},get_total_points:function(){var e=0;return this.get("sections").each(function(t){t.get("lessons").each(function(t){var i=t.get("points");_.isNumber(i)||(i=0),e+=1*i})}),e}},t,i))}),n("Models/loader",["Models/Abstract","Models/Course","Models/Image","Models/Lesson","Models/Question","Models/QuestionChoice","Models/QuestionType","Models/Quiz","Models/Section"],function(e,t,i,n,s,o,l,r,a){return{Abstract:e,Course:t,Image:i,Lesson:n,Question:s,QuestionChoice:o,QuestionType:l,Quiz:r,Section:a}}),n("Views/_Detachable",[],function(){return{events:{'click a[href="#llms-detach-model"]':"detach_model"},detach_model:function(e){e&&(e.preventDefault(),e.stopPropagation());var t=LLMS.l10n.replace("Are you sure you want to detach this %s?",{"%s":this.model.get_l10n_type()});window.confirm(t)&&(this.model.collection&&this.model.collection.remove(this.model),Backbone.pubSub.trigger("model-detached",this.model),this.trigger("model-trashed",this.model))}}}),n("Views/_Editable",[],function(){return{media_lib:null,events:{"click .llms-add-image":"open_media_lib",'click a[href="#llms-edit-slug"]':"make_slug_editable",'click a[href="#llms-remove-image"]':"remove_image","change .llms-editable-select select":"on_select",'change .llms-switch input[type="checkbox"]':"toggle_switch","change .llms-editable-radio input":"on_radio_select","focusin .llms-input":"on_focus","focusout .llms-input":"on_blur","keydown .llms-input":"on_keydown",'input .llms-input[type="number"]':"on_blur","paste .llms-input[data-formatting]":"on_paste"},get_allowed_tags:function(e){return e.attr("data-formatting")?_.map(e.attr("data-formatting").split(","),function(e){return e.trim()}):["b","i","u","strong","em"]},get_content:function(e){return"INPUT"===e[0].tagName?e.val():e.attr("data-formatting")||e.hasClass("ql-editor")?_.stripFormatting(e.html(),this.get_allowed_tags(e)):e.text()},has_changed:function(t){var i=e(t.target);return i.attr("data-original-content")!==this.get_content(i)},is_valid:function(t){var i=this,n=e(t.target),s=this.get_content(n),o=n.attr("data-type");if((n.attr("required")||n.attr("data-required"))&&s.length<1)return!1;if("url"===o||"video"===o){if(!this._validate_url(this.get_content(n)))return!1}else"permalink"===o&&LLMS.Ajax.call({data:{action:"llms_builder",action_type:"get_permalink",course_id:window.llms_builder.CourseModel.get("id"),id:i.model.get("id"),title:i.model.get("title"),slug:s},beforeSend:function(){LLMS.Spinner.start(n.closest(".llms-editable-toggle-group"),"small")},success:function(e){e.permalink&&e.slug&&(i.model.set("permalink",e.permalink),i.model.set("name",e.slug),i.render())}});return!0},init_datepickers:function(){this.$el.find(".llms-editable-date input").each(function(){e(this).datetimepicker({format:e(this).attr("data-date-format")||"Y-m-d h:i A",datepicker:void 0===e(this).attr("data-date-datepicker")||"true"==e(this).attr("data-date-datepicker"),timepicker:void 0===e(this).attr("data-date-timepicker")||"true"==e(this).attr("data-date-timepicker"),onClose:function(e,t){t.blur()}})})},init_formatting_els:function(){var t=this;this.$el.find(".llms-input-formatting[data-formatting]").each(function(){var i=e(this).attr("data-formatting").split(","),n=e(this).attr("data-attribute"),s=new Quill(this,{modules:{toolbar:[i],keyboard:{bindings:{tab:{key:9,handler:function(e,t){return!0}},13:{key:13,handler:function(e,t){return s.root.blur(),!1}}}}},placeholder:e(this).attr("data-placeholder"),theme:"bubble"});s.on("text-change",function(i,o,l){t.model.set(n,t.get_content(e(s.root)))}),Backbone.pubSub.trigger("formatting-ed-init",s,e(this),t)})},init_selects:function(){this.$el.find(".llms-editable-select select").llmsSelect2({width:"100%"}).trigger("change")},on_blur:function(t){t.stopPropagation(),this.model.set("_has_focus",!1,{silent:!0});var i=this;e(t.target);this.has_changed(t)&&(i.is_valid(t)?this.save_edits(t):i.revert_edits(t))},on_focus:function(e){e.stopPropagation(),this.model.set("_has_focus",!0,{silent:!0})},on_paste:function(e){e.preventDefault(),e.stopPropagation();var t=(e.originalEvent||e).clipboardData.getData("text/plain");window.document.execCommand("insertText",!1,t)},on_select:function(t){var i,n=e(t.target),s=n.attr("multiple"),o=n.attr("name"),l=n.find("option:selected");s?(i=[],i=l.map(function(){return this.value}).get()):i=l[0].value,this.model.set(o,i)},on_radio_select:function(t){var i=e(t.target),n=i.attr("name"),s=i.val();this.model.set(n,s)},on_keydown:function(e){e.stopPropagation();var t=e.which||e.keyCode,i=e.shiftKey;switch(t){case 13:i||(e.preventDefault(),e.target.blur());break;case 27:e.preventDefault(),this.revert_edits(e),e.target.blur()}},open_media_lib:function(t){t.stopPropagation();var i=this,n=e(t.currentTarget);i.media_lib?i.media_lib.uploader.uploader.param("post_id"):(i.media_lib=wp.media.frames.file_frame=wp.media({title:LLMS.l10n.translate("Select an image"),button:{text:LLMS.l10n.translate("Use this image")},multiple:!1}),i.media_lib.on("select",function(){var e,t=n.attr("data-image-size"),s=i.media_lib.state().get("selection").first().toJSON(),o=i.model.get(n.attr("data-attribute"));e=t&&s.sizes[t]?s.sizes[t].url:s.url,o.set({id:s.id,src:e})})),i.media_lib.open()},remove_image:function(t){t.preventDefault(),this.model.get(e(t.currentTarget).attr("data-attribute")).set({id:"",src:""})},revert_edits:function(t){var i=e(t.target),n=i.attr("data-original-content");i.html(n)},save_edits:function(t){var i=e(t.target),n=this.get_content(i);this.model.set(i.attr("data-attribute"),n)},toggle_switch:function(t){t.stopPropagation();var i,n=e(t.target),s=n.attr("name"),o=n.attr("data-rerender");if(i=n.is(":checked")?n.attr("data-on")?n.attr("data-on"):"yes":n.attr("data-off")?n.attr("data-off"):"no",-1!==s.indexOf(".")){var l=s.split(".");"parent"===l[0]?this.model.get_parent().set(l[1],i):this.model.get(l[0]).set(l[1],i)}else this.model.set(s,i);if(this.trigger(s.replace(".","-")+"_toggle",i),!o||"yes"===o){var r=this;setTimeout(function(){r.render()},100)}},init_editor:function(t,i){i=i||{};var n=_.getEditor();n.remove(t),n.initialize(t,e.extend(!0,n.getDefaultSettings(),{mediaButtons:!0,tinymce:{toolbar1:"bold,italic,strikethrough,bullist,numlist,blockquote,hr,alignleft,aligncenter,alignright,link,unlink,wp_adv",toolbar2:"formatselect,underline,alignjustify,forecolor,pastetext,removeformat,charmap,outdent,indent,undo,redo,wp_help",setup:_.bind(this.on_editor_ready,this)}},i))},make_slug_editable:function(t){var i=e(t.currentTarget),n=i.prevAll("a"),s=i.prev("input.permalink"),o=n.attr("href"),l=s.val(),r=o.replace(l,"");i.hide(),n.css({color:"#999","pointer-events":"none","text-decoration":"none"}),n.text(r.substring(0,r.length-1)),s.show().focus()},on_editor_ready:function(t){var i=this,n=e("#"+t.id),s=n.closest(".llms-editable-editor"),o=s.find(".llms-label"),l=n.attr("data-attribute");o.length&&o.prependTo(s.find(".wp-editor-tools")),t.on("change",function(e){i.model.set(l,_.getEditor().getContent(t.id))}),n.on("input",function(e){i.model.set(l,n.val())}),s.on("click",".quicktags-toolbar .ed_button",function(){setTimeout(function(){n.trigger("input")},10)})},_validate_url:function(e){var t=document.createElement("a");return t.href=e,t.host&&t.host!==window.location.host}}}),n("Views/_Receivable",[],function(){return{_receive:function(e,t){if(t.sender.hasClass("ui-draggable")){var i=this._getContainerEl().children().index(t.helper);return t.helper.remove(),void this.collection.add({},{at:i})}var n=t.sender,s=n.data("view");if(s&&s.collection){var o=this._getContainerEl().children().index(t.item),l=s.collection.get(t.item.attr("data-model-cid")) ;s.collection.remove(l),this.collection.add(l,{at:o}),l.collection=this.collection,this.setSelectedModel(l)}}}}),n("Views/_Shiftable",[],function(){return{maybe_hide_shiftable_buttons:function(){if(this.model.collection){var e=this.model.get("type");this.model.collection.first()===this.model?this.$el.find(".shift-up--"+e).hide():this.model.collection.last()===this.model&&this.$el.find(".shift-down--"+e).hide()}},shift:function(e,t){var i=this.model.collection;i.remove(this.model),i.add(this.model,{at:t}),i.trigger("reorder")},shift_down:function(e){e.preventDefault();var t=this.model.collection.indexOf(this.model);this.shift(t,t+1)},shift_up:function(e){e.preventDefault();var t=this.model.collection.indexOf(this.model);this.shift(t,t-1)}}}),n("Views/_Subview",[],function(){return{subscriptions:{},state:"",views:{},get_subview:function(e){return!!this.views[e]&&this.views[e]},events_subscribe:function(e){_.each(e,function(e,t){this.subscriptions[t]=e,Backbone.pubSub.on(t,e,this)},this)},events_unsubscribe:function(){_.each(this.subscriptions,function(e,t){Backbone.pubSub.off(t,e,this),delete this.subscriptions[t]},this)},remove_subview:function(e){var t=this.get_subview(e);t&&t.instance&&(_.isEmpty(t.instance.views)||(t.instance.events_unsubscribe(),t.instance.remove_subviews()),t.instance.off(),t.instance.off(null,null,null),t.instance.remove(),t.instance.undelegateEvents(),t.instance=null)},remove_subviews:function(){_.each(this.views,function(e,t){this.remove_subview(t)},this)},render_subviews:function(e){e=e||{},_.each(this.views,function(t,i){this.state===t.state?this.render_subview(i,e):this.remove_subview(i)},this)},render_subview:function(e,t){var i=this.get_subview(e);i&&(this.remove_subview(e),i.instance||(i.instance=new i.class(t)),i.instance.render())},set_state:function(e){return this.state=e,this}}}),n("Views/_Trashable",[],function(){return{events:{'click a[href="#llms-trash-model"]':"trash_model"},trash_model:function(e){e&&(e.preventDefault(),e.stopPropagation());var t=LLMS.l10n.replace("Are you sure you want to move this %s to the trash?",{"%s":this.model.get_l10n_type()});window.confirm(t)&&(this.model.collection&&this.model.collection.remove(this.model),Backbone.pubSub.trigger("model-trashed",this.model),this.trigger("model-trashed",this.model))}}}),n("Views/_loader",["Views/_Detachable","Views/_Editable","Views/_Receivable","Views/_Shiftable","Views/_Subview","Views/_Trashable"],function(e,t,i,n,s,o){return{Detachable:e,Editable:t,Receivable:i,Shiftable:n,Subview:s,Trashable:o}}),n("Controllers/Construct",["Collections/loader","Models/loader","Views/_loader"],function(e,t,i){return function(){function n(e,t,i,n){return e[t]?new e[t](i,n):(console.log('"'+t+'" not found.'),!1)}return this.get_collection=function(t,i,s){return n(e,t,i,s)},this.get_model=function(e,i,s){return n(t,e,i,s)},this.extend_view=function(){for(var e=arguments[0],t=1;arguments[t];){var n=arguments[t];i[n]&&(e.events&&i[n].events&&(e.events=_.defaults(e.events,i[n].events)),e=_.defaults(e,i[n])),t++}return Backbone.View.extend(e)},this.register_collection=function(t,i){e[t]=Backbone.Collection.extend(i)},this.register_model=function(e,i){t[e]=t.Abstract.extend(i)},this}}),n("Controllers/Debug",[],function(){return function(e){var t=this,i=e.enabled||!1;this.disable=function(){t.log("LifterLMS Builder debugging disabled"),i=!1},this.enable=function(){i=!0,t.log("LifterLMS Builder debugging enabled")},this.log=function(){i&&_.each(arguments,function(e){console.log(e)})},this.toggle=function(){i?t.disable():t.enable()},i&&t.enable()}}),n("Controllers/Schemas",[],function(){return function(e){var t=e;return _.each(t,function(e){_.each(e,function(e){e.custom=!0})}),this.get=function(e,i,n){return t[i]&&(e=_.extend(e,t[i])),e},this}}),n("Controllers/Sync",[],function(){return function(t,i){function n(e,t){return"success"===e.status&&(e.message=[]),e.status="error","string"==typeof t&&(t=[t]),e.message=e.message.concat(t),e}function s(){var e={};e.changes=p.get_unsaved_changes(),e.has_unsaved_changes=p.has_unsaved_changes(e.changes),e.saving=p.saving,window.llms_builder.debug.log("==== start changes check ====",e,"==== finish changes check ===="),Backbone.pubSub.trigger("current-save-status",e)}function o(){if(!p.saving){var e=p.get_unsaved_changes();p.has_unsaved_changes(e)&&(e.id=t.get("id"),LLMS.Ajax.call({data:{action:"llms_builder",action_type:"ajax_save",course_id:e.id,llms_builder:JSON.stringify(e)},beforeSend:function(){window.llms_builder.debug.log("==== start do_ajax_save before ====",e,"==== finish do_ajax_save before ===="),p.saving=!0,Backbone.pubSub.trigger("heartbeat-send",p)},error:function(e,t,i){window.llms_builder.debug.log("==== start do_ajax_save error ====",e,"==== finish do_ajax_save error ===="),p.saving=!1,Backbone.pubSub.trigger("heartbeat-tick",p,{status:"error",message:e.responseText+" ("+i+" "+t+")"})},success:function(e){e.llms_builder&&(window.llms_builder.debug.log("==== start do_ajax_save success ====",e,"==== finish do_ajax_save success ===="),e.llms_builder=d(e.llms_builder),e.llms_builder=h(e.llms_builder),p.saving=!1,Backbone.pubSub.trigger("heartbeat-tick",p,e.llms_builder))}}))}}function l(e){var t,i={};if(e.get("_has_focus"))return i;a(e)||!0===e.get("_forceSync")?(i=_.clone(e.attributes),t="full"):(i=e.unsavedAttributes(),t="partial");var n=e.get_relationships?e.get_child_props():[];return i=_.omit(i,function(e,t){return 0===t.indexOf("_")||-1!==n.indexOf(t)}),e.before_save&&(i=e.before_save(i,t)),i}function r(e){var t;return e instanceof Backbone.Model?(t=l(e),e.get_relationships&&_.each(e.get_child_props(),function(i){var n=r(e.get(i));_.isEmpty(n)||(t[i]=n)}),_.isEmpty(t)||(t.id=e.get("id"))):e instanceof Backbone.Collection&&(t=[],e.each(function(e){var i=r(e);_.isEmpty(i)||t.push(i)})),t}function a(e){return!_.isNumber(e.id)&&0===e.id.indexOf("temp_")}function c(e,t){Backbone.pubSub.trigger(e.get("type")+"-maybe-restart-tracking",e,t);var i=["id","orig_id"];e.get_relationships&&i.concat(e.get_child_props()),_.each(_.omit(t,i),function(t,i){_.isEqual(e.get(i),t)&&(delete e._unsavedChanges[i],e._originalAttrs[i]=t)}),e.unset("_forceSync")}function d(e){var t={detach:b,trash:v};return _.each(t,function(t,i){if(e[i]){var s=[];_.each(e[i],function(e){e.error?s.push(e.error):t.remove(e.id)}),s.length&&_.extend(e,n(e,s))}}),e}function u(e,t,i,s){if(!e[t])return e;if(i.get(t)instanceof Backbone.Model){var o=e[t];if(o.error)_.extend(s,n(s,o.error));else{var l=i.get(t);o.id!=o.orig_id&&(l.set("id",o.id),delete l._unsavedChanges.id),c(l,o),l.get_relationships&&_.each(l.get_child_props(),function(i){_.extend(e[t],u(e[t],i,l,s))})}}else i.get(t)instanceof Backbone.Collection&&_.each(e[t],function(o,l){if(o.error)_.extend(s,n(s,o.error));else{var r=i.get(t).get(o.orig_id);o.id!=o.orig_id&&(r.set("id",o.id),delete r._unsavedChanges.id),c(r,o),r.get_relationships&&_.each(r.get_child_props(),function(i){_.extend(e[t],u(e[t][l],i,r,s))})}});return s}function h(e){return e.updates?(e.updates&&(e=u(e.updates,"sections",t,e)),e):e}this.saving=!1;var p=this,m="yes"===window.llms_builder.autosave,g=null,f=i.check_interval_ms||1e4,b=new Backbone.Collection,v=new Backbone.Collection;return this.get_unsaved_changes=function(){return{detach:b.pluck("id"),trash:v.pluck("id"),updates:r(t)}},this.has_unsaved_changes=function(e){return void 0===e&&(e=p.get_unsaved_changes()),!!_.find(e,function(e){return!1===_.isEmpty(e)})},this.save_now=function(){m?wp.heartbeat.connectNow():o()},this.set_check_interval=function(e){f=e,g&&clearInterval(g),f&&(g=setInterval(s,f))},Backbone.pubSub.on("model-detached",function(e){a(e)||b.add(_.clone(e.attributes))}),Backbone.pubSub.on("model-trashed",function(e){if(!a(e)){var t=_.clone(e.attributes);e.get_trash_id&&(t.id=e.get_trash_id()),v.add(t)}}),e(document).on("heartbeat-send",function(e,i){if(m&&!p.saving){var n=p.get_unsaved_changes();p.has_unsaved_changes(n)&&(n.id=t.get("id"),p.saving=!0,i.llms_builder=JSON.stringify(n)),window.llms_builder.debug.log("==== start heartbeat-send ====",i,"==== finish heartbeat-send ===="),Backbone.pubSub.trigger("heartbeat-send",p)}}),e(document).on("heartbeat-tick",function(e,t){m&&t.llms_builder&&(window.llms_builder.debug.log("==== start heartbeat-tick ====",t,"==== finish heartbeat-tick ===="),t.llms_builder=d(t.llms_builder),t.llms_builder=h(t.llms_builder),p.saving=!1,Backbone.pubSub.trigger("heartbeat-tick",p,t.llms_builder))}),e(document).on("heartbeat-error",function(e,t){m&&(window.llms_builder.debug.log("==== start heartbeat-error ====",t,"==== finish heartbeat-error ===="),p.saving=!1,Backbone.pubSub.trigger("heartbeat-tick",p,{status:"error",message:t.responseText+" ("+t.status+" "+t.statusText+")"}))}),function(){void 0===wp.heartbeat&&(window.llms_builder.debug.log("WordPress Heartbeat disabled. Autosaving is disabled!"),m=!1),f&&p.set_check_interval(f),e(window).on("beforeunload",function(){if(p.has_unsaved_changes())return s(),"Are you sure you want to abandon your changes?"})}(),this}}),n("Views/Lesson",["Views/_Detachable","Views/_Editable","Views/_Shiftable","Views/_Trashable"],function(e,t,i,n){return Backbone.View.extend(_.defaults({attributes:function(){return{"data-id":this.model.id,"data-section-id":this.model.get("parent_section")}},className:"llms-builder-item llms-lesson",events:_.defaults({"click .edit-lesson":"open_lesson_editor","click .edit-quiz":"open_quiz_editor","click .edit-assignment":"open_assignment_editor","click .section-prev":"section_prev","click .section-next":"section_next","click .shift-up--lesson":"shift_up","click .shift-down--lesson":"shift_down"},e.events,t.events,n.events),id:function(){return"llms-lesson-"+this.model.id},tagName:"li",template:wp.template("llms-lesson-template"),initialize:function(){this.render(),this.listenTo(this.model,"change",this.render),Backbone.pubSub.on("lesson-selected",this.on_select,this),Backbone.pubSub.on("new-lesson-added",this.on_select,this)},render:function(){return this.$el.html(this.template(this.model)),this.maybe_hide_shiftable_buttons(),this.model.get("_selected")?this.$el.addClass("selected"):this.$el.removeClass("selected"),this},open_assignment_editor:function(e){e&&e.preventDefault(),Backbone.pubSub.trigger("lesson-selected",this.model,"assignment"),this.model.set("_selected",!0),this.set_hash("assignment")},open_lesson_editor:function(e){e&&e.preventDefault(),Backbone.pubSub.trigger("lesson-selected",this.model,"lesson"),this.model.set("_selected",!0),this.set_hash(!1)},open_quiz_editor:function(e){e&&e.preventDefault(),Backbone.pubSub.trigger("lesson-selected",this.model,"quiz"),this.model.set("_selected",!0),this.set_hash("quiz")},on_select:function(e){this.model.id!==e.id&&this.model.set("_selected",!1)},section_next:function(e){e.preventDefault(),this._move_to_section("next")},section_prev:function(e){e.preventDefault(),this._move_to_section("prev")},set_hash:function(e){var t="lesson:"+this.model.get("id");e&&(t+=":"+e),window.location.hash=t},_move_to_section:function(e){var t,i=this.model.collection;"next"===e?t=i.parent.get_next():"prev"===e&&(t=i.parent.get_prev()),t&&(i.remove(this.model),t.add_lesson(this.model),t.set("_expanded",!0))}},e,t,i,n))}),n("Views/LessonList",["Views/Lesson","Views/_Receivable"],function(t,i){return Backbone.CollectionView.extend(_.defaults({className:"llms-lessons",modelView:t,selectable:!1,sortable:!0,sortableOptions:{axis:!1,connectWith:".llms-lessons",cursor:"move",handle:".drag-lesson",items:".llms-lesson",placeholder:"llms-lesson llms-sortable-placeholder"},sortable_start:function(t){e(".llms-lessons").addClass("dragging")},sortable_stop:function(t){e(".llms-lessons").removeClass("dragging")},_sortStop:function(e,t){var i=this.collection.get(t.item.attr("data-model-cid")),n=this._getContainerEl(),s=n.children().index(t.item);-1==s&&i&&this.collection.remove(i),this._reorderCollectionBasedOnHTML(),this.updateDependentControls(),this._isBackboneCourierAvailable()?this.spawn("sortStop",{modelBeingSorted:i,newIndex:s}):this.trigger("sortStop",i,s)}},i))}),n("Views/Section",["Views/LessonList","Views/_Editable","Views/_Shiftable","Views/_Trashable"],function(t,i,n,s){return Backbone.View.extend(_.defaults({attributes:function(){return{"data-id":this.model.id}},className:"llms-builder-item llms-section",events:_.defaults({click:"select","click .expand":"expand","click .collapse":"collapse","click .shift-up--section":"shift_up","click .shift-down--section":"shift_down","mouseenter .llms-lessons":"on_mouseenter"},i.events,s.events),id:function(){return"llms-section-"+this.model.id},tagName:"li",template:wp.template("llms-section-template"),initialize:function(){this.render(),this.listenTo(this.model,"change",this.render),this.listenTo(this.model,"change:_expanded",this.toggle_expanded),this.lessonListView.collection.on("add",this.on_lesson_add,this),this.dragTimeout=null,Backbone.pubSub.on("expand-all",this.expand,this),Backbone.pubSub.on("collapse-all",this.collapse,this)},render:function(){return this.$el.html(this.template(this.model.toJSON())),this.maybe_hide_shiftable_buttons(),this.lessonListView=new t({el:this.$el.find(".llms-lessons"),collection:this.model.get("lessons")}),this.lessonListView.render(),this.lessonListView.on("sortStart",this.lessonListView.sortable_start),this.lessonListView.on("sortStop",this.lessonListView.sortable_stop),this.lessonListView.on("selectionChanged",this.active_lesson_change,this),this.maybe_hide_trash_button(),this},active_lesson_change:function(e,t){Backbone.pubSub.trigger("active-lesson-change",{current:e,previous:t})},collapse:function(e,t){void 0===t&&(t=!0),e&&(e.stopPropagation(),e.preventDefault()),this.$el.removeClass("expanded").find(".drag-expanded").removeClass("drag-expanded"),t&&this.model.set("_expanded",!1),Backbone.pubSub.trigger("section-toggle",this.model)},expand:function(e,t){void 0===t&&(t=!0),e&&(e.stopPropagation(),e.preventDefault()),this.$el.addClass("expanded"),t&&this.model.set("_expanded",!0),Backbone.pubSub.trigger("section-toggle",this.model)},maybe_hide_trash_button:function(){var e=this.$el.find(".trash--section");this.model.get("lessons").isEmpty()?e.show():e.hide()},on_lesson_add:function(e){this.lessonListView.collection.trigger("reorder"),e.set("parent_section",this.model.get("id")),this.expand()},on_mouseenter:function(t){e(t.target).hasClass("dragging")&&(e(".drag-expanded").removeClass("drag-expanded"),e(t.target).addClass("drag-expanded"))},toggle_expanded:function(e,t){t?this.expand(null,!1):this.collapse(null,!1)}},i,n,s))}),n("Views/SectionList",["Views/Section","Views/_Receivable"],function(e,t){return Backbone.CollectionView.extend(_.defaults({el:"#llms-sections",events:{"mousedown > li.llms-section > .llms-builder-header .llms-headline":"_listItem_onMousedown",click:"_listBackground_onClick","click ul.collection-view":"_listBackground_onClick",keydown:"_onKeydown"},modelView:e,processKeyEvents:!1,selectable:!0,sortable:!0,sortableOptions:{axis:!1,cursor:"move",handle:".drag-section",items:".llms-section",placeholder:"llms-section llms-sortable-placeholder"},sortable_start:function(e){this.$el.addClass("dragging")},sortable_stop:function(e){this.$el.removeClass("dragging")}},t))}),n("Views/Course",["Views/SectionList","Views/_Editable"],function(e,t){return Backbone.View.extend(_.defaults({attributes:function(){return{"data-id":this.model.id}},el:"#llms-builder-main",tagName:"div",template:wp.template("llms-course-template"),initialize:function(){this.render(),this.sectionListView=new e({collection:this.model.get("sections")}),this.sectionListView.render(),this.sectionListView.on("sortStart",this.sectionListView.sortable_start),this.sectionListView.on("sortStop",this.sectionListView.sortable_stop),this.sectionListView.on("selectionChanged",this.active_section_change),this.listenTo(this.model.get("sections"),"add",this.on_section_add),Backbone.pubSub.on("section-toggle",this.on_section_toggle,this),Backbone.pubSub.on("expand-section",this.expand_section,this),Backbone.pubSub.on("lesson-selected",this.active_lesson_change,this)},render:function(){return this.$el.html(this.template(this.model)),this},active_lesson_change:function(e){var t=this.model.get("sections").get(e.get("parent_section"));this.sectionListView.setSelectedModel(t)},active_section_change:function(e,t){_.each(e,function(e){e.set("_selected",!0)}),_.each(t,function(e){e.set("_selected",!1)})},on_section_add:function(e){this.sectionListView.setSelectedModel(e)},on_section_toggle:function(e){var t=e.get("_expanded")?[e]:[];this.sectionListView.setSelectedModels(t)}},t))}),n("Views/SettingsFields",[],function(){return Backbone.View.extend(_.defaults({events:{"click .llms-settings-group-toggle":"toggle_group"},fields:{},tagName:"div",template:wp.template("llms-settings-fields-template"),get_editor_fields:function(){return _.filter(this.fields,function(e){return this.is_editor_field(e.type)},this)},get_groups:function(){return this.model.get_settings_fields()},is_group_hidden:function(e){var t="llms-"+this.model.get("type")+"-settings-group--"+e;return"undefined"!==window.localStorage&&"hidden"===window.localStorage.getItem(t)},get_switch_attribute:function(e){return e.switch_attribute?e.switch_attribute:e.attribute},has_switch:function(e){return-1!==e.indexOf("switch")},is_default_field:function(e){return-1!==["audio_embed","datepicker","number","text","video_embed"].indexOf(e.replace("switch-",""))},is_editor_field:function(e){return-1!==["editor","switch-editor"].indexOf(e.replace("switch-",""))},is_switch_condition_met:function(e){return e.switch_on===this.model.get(e.switch_attribute)},render:function(){return this.$el.html(this.template(this)),_.each(this.get_editor_fields(),function(e){this.render_editor(e)},this),this},render_editor:function(t){var i=this,n=_.getEditor();if(void 0===n)return void console.error("Unable to access `wp.oldEditor` or `wp.editor`.");n.remove(t.id),t.settings.tinymce.setup=function(t){var s=e("#"+t.id),o=s.closest(".llms-editable-editor"),l=o.find(".llms-label"),r=s.attr("data-attribute");l.length&&l.prependTo(o.find(".wp-editor-tools")),t.on("change",function(e){i.model.set(r,n.getContent(t.id))}),s.on("input",function(e){i.model.set(r,s.val())}),o.on("click",".quicktags-toolbar .ed_button",function(){setTimeout(function(){s.trigger("input")},10)})},n.initialize(t.id,t.settings)},render_select_options:function(e,t){function i(e,t){return'"}var n="",s=this.model.get(t);return _.each(e,function(e,s){"string"==typeof e?n+=i(e,s):"object"==typeof e&&(e.label&&e.options?(n+='',n+=this.render_select_options(e.options,t)):n+=i(e.val,e.key))},this),n},setup_field:function(t,i){var n={classes:[],id:_.uniqueId(t.attribute+"_"),input_type:"text",label:"",options:{},placeholder:"",tip:"",tip_position:"top-right",settings:{}};if(t.condition&&!1===_.bind(t.condition,this.model)())return!1;switch(t.type){case"audio_embed":n.classes.push("llms-editable-audio"),n.placeholder="https://",n.tip=LLMS.l10n.translate("Use SoundCloud or Spotify audio URLS."),n.input_type="url";break;case"datepicker":n.classes.push("llms-editable-date");break;case"editor":case"switch-editor":var s=t.settings||{};n.settings=e.extend(!0,_.getEditor().getDefaultSettings(),{mediaButtons:!0,tinymce:{toolbar1:"bold,italic,strikethrough,bullist,numlist,blockquote,hr,alignleft,aligncenter,alignright,link,unlink,wp_adv",toolbar2:"formatselect,underline,alignjustify,forecolor,pastetext,removeformat,charmap,outdent,indent,undo,redo,wp_help"}},s);break;case"number":case"switch-number":n.input_type="number";break;case"permalink":n.label=LLMS.l10n.translate("Permalink");break;case"video_embed":n.classes.push("llms-editable-video"),n.placeholder="https://",n.tip=LLMS.l10n.translate("Use YouTube, Vimeo, or Wistia video URLS."),n.input_type="url"}this.has_switch(t.type)&&(n.switch_on="yes",n.switch_off="no");var o=_.defaults(_.deepClone(t),n);if(_.isFunction(o.options)&&(o.options=_.bind(o.options,this.model)()),-1!==["radio","switch-radio"].indexOf(t.type)){var l=!1;_.each(t.options,function(e,t){-1===e.indexOf(".png")&&-1===e.indexOf(".jpg")||(o.options[t]='',l=!0)}),l&&o.classes.push("has-images")}return o.classes.length&&(o.classes=" "+o.classes.join(" ")),this.fields[o.id]=o,o},should_rerender_on_toggle:function(e){return-1!==e.indexOf("switch-")?"yes":"no"},toggle_group:function(t){t.preventDefault();var i=e(t.currentTarget),n=i.closest(".llms-model-settings");if(n.toggleClass("hidden"),"undefined"!==window.localStorage){var s=n.attr("id");n.hasClass("hidden")?window.localStorage.setItem(s,"hidden"):window.localStorage.removeItem(s)}}}))}),n("Views/LessonEditor",["Views/_Detachable","Views/_Editable","Views/_Trashable","Views/_Subview","Views/SettingsFields"],function(e,t,i,n,s){return Backbone.View.extend(_.defaults({state:"default",views:{settings:{class:s,instance:null,state:"default"}},el:"#llms-editor-lesson",events:_.defaults({},e.events,t.events,i.events),template:wp.template("llms-lesson-settings-template"),initialize:function(e){this.model=e.lesson;var t=window.llms.hooks.applyFilters("llms_lesson_rerender_change_events",["change:date_available","change:drip_method","change:time_available"]);_.each(t,function(e){this.listenTo(this.model,e,this.render)},this),this.listenTo(this.model,"change:points",this.render_points_percentage),this.listenTo(this.model,"change:has_prerequisite",function(e,t){"yes"===t&&this.$el.find('select[name="prerequisite"]').trigger("change")})},render:function(){return this.$el.html(this.template(this.model)),this.remove_subview("settings"),this.render_subview("settings",{el:"#llms-lesson-settings-fields",model:this.model}),this.init_datepickers(),this.init_selects(),this.render_points_percentage(),this},render_points_percentage:function(){this.$el.find("#llms-model-settings-field--points .llms-editable-input").addClass("tip--top-left").attr("data-tip",this.model.get_points_percentage())}},e,t,i,n,s))}),n("Views/Popover",[],function(){return Backbone.View.extend({defaults:{placement:"auto",width:"auto",trigger:"manual",style:"light",animation:"pop",title:"",content:"",closeable:!1,backdrop:!1,onShow:function(e){},onHide:function(e){}},tagName:"div",initialize:function(t){this.$el.length&&(this.defaults.container=this.$el.parent()),this.args=_.defaults(t.args,this.defaults),e("body").hasClass("rtl")&&(-1!==this.args.placement.indexOf("left")?this.args.placement=this.args.placement.replace("left","right"):-1!==this.args.placement.indexOf("right")&&(this.args.placement=this.args.placement.replace("right","left"))),this.render()},render:function(){return this.$el.webuiPopover(this.args),this},hide:function(){return this.$el.webuiPopover("hide"),this},show:function(){return this.$el.webuiPopover("show"),this}})}),n("Views/PostSearch",[],function(){return Backbone.View.extend({events:{"select2:select":"add_post"},tagName:"select",initialize:function(e){this.post_type=e.post_type,this.searching_message=e.searching_message||LLMS.l10n.translate("Searching...")},add_post:function(e){var t=this.$el.attr("data-post-type");Backbone.pubSub.trigger(t.replace("llms_","")+"-search-select",e.params.data,e),this.$el.val(null).trigger("change")},render:function(){var t=this;return setTimeout(function(){t.$el.llmsSelect2({ajax:{dataType:"JSON",delay:250,method:"POST",url:window.ajaxurl,data:function(e){return{action:"llms_builder",action_type:"search",course_id:window.llms_builder.course.id,post_type:t.post_type,term:e.term,page:e.page,_ajax_nonce:window.llms.ajax_nonce}}},dropdownParent:e(".wrap.lifterlms.llms-builder"),escapeMarkup:function(e){return e},placeholder:t.searching_message,templateResult:t.render_result,width:"100%"}),t.$el.attr("data-post-type",t.post_type)},0),this},render_result:function(t){var i=e('
    ');if(t.loading)return i.append(t.text);var n=e('