Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions cms/static/sass/course-unit-mfe-iframe-bundle.scss
Original file line number Diff line number Diff line change
Expand Up @@ -618,6 +618,42 @@ body,
}
}

.lib-edit-warning-tooltipbox {
.tooltiptext {
visibility: hidden;
position: absolute;
width: 200px;
background-color: $black;
color: $white;
text-align: center;
padding: 5px;
border-radius: 6px;
z-index: 1;
top: 50%;
right: 100%;
margin-right: 10px;
transform: translateY(-50%);
opacity: 0;
transition: opacity 0.3s;
}

.tooltiptext::after {
content: "";
position: absolute;
top: 50%;
left: 100%;
transform: translateY(-50%);
border-width: 5px;
border-style: solid;
border-color: transparent transparent transparent $black;
}

&:hover .tooltiptext {
visibility: visible;
opacity: 1;
}
}

.action-edit {
.action-button-text {
display: none;
Expand All @@ -632,6 +668,13 @@ body,
display: none;
}

&.disabled-button {
pointer-events: all;
opacity: .5;
cursor: default;
border-color: $transparent
}

&::before {
@extend %icon-position;

Expand Down
14 changes: 13 additions & 1 deletion cms/templates/studio_xblock_wrapper.html
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@
% endif
% if not show_inline:
<li class="action-item action-edit">
<button class="btn-default edit-button action-button" data-usage-id=${xblock.scope_ids.usage_id}>
<button class="btn-default edit-button action-button" data-usage-id=${xblock.scope_ids.usage_id} data-tooltip="${_("Edit")}">
<span class="icon fa fa-pencil" aria-hidden="true"></span>
<span class="action-button-text">${_("Edit")}</span>
</button>
Expand Down Expand Up @@ -211,6 +211,18 @@
<span data-tooltip="${_('Drag to reorder')}" class="drag-handle action"></span>
</li>
% endif
% else:
% if not show_inline:
<li class="action-item action-edit">
<div class="lib-edit-warning-tooltipbox">
<button class="btn-default edit-button action-button disabled-button" data-usage-id=${xblock.scope_ids.usage_id} disabled>
<span class="icon fa fa-pencil" aria-hidden="true"></span>
<span class="action-button-text">${_("Edit")}</span>
</button>
<span class="tooltiptext">${_('Components within a library referenced object cannot be edited')}</span>
</div>
</li>
% endif
% endif
% endif
</ul>
Expand Down
2 changes: 2 additions & 0 deletions common/djangoapps/third_party_auth/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -787,6 +787,7 @@ def associate_by_email_if_saml(auth_entry, backend, details, user, strategy, *ar

This association is done ONLY if the user entered the pipeline belongs to SAML provider.
"""
from openedx.features.enterprise_support.api import enterprise_is_enabled

def get_user():
"""
Expand All @@ -795,6 +796,7 @@ def get_user():
user_details = {'email': details.get('email')} if details else None
return get_user_from_email(user_details or {})

@enterprise_is_enabled()
def associate_by_email_if_enterprise_user():
"""
If the learner arriving via SAML is already linked to the enterprise customer linked to the same IdP,
Expand Down
2 changes: 1 addition & 1 deletion lms/envs/production.py
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,7 @@ def get_env_setting(setting):
# If we didn't override the value in YAML, OR we overrode it to a truthy value,
# then update CELERYBEAT_SCHEDULE.
CELERYBEAT_SCHEDULE['refresh-saml-metadata'] = {
'task': 'common.djangoapps.third_party_auth.fetch_saml_metadata',
'task': 'common.djangoapps.third_party_auth.tasks.fetch_saml_metadata',
'schedule': datetime.timedelta(hours=hours),
}

Expand Down
6 changes: 1 addition & 5 deletions requirements/common_constraints.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,9 @@
# this file from Github directly. It does not require packaging in edx-lint.

# using LTS django version
Django<5.0
Django<6.0

# elasticsearch>=7.14.0 includes breaking changes in it which caused issues in discovery upgrade process.
# elastic search changelog: https://www.elastic.co/guide/en/enterprise-search/master/release-notes-7.14.0.html
# See https://github.com/openedx/edx-platform/issues/35126 for more info
elasticsearch<7.14.0

# Cause: https://github.com/openedx/edx-lint/issues/458
# This can be unpinned once https://github.com/openedx/edx-lint/issues/459 has been resolved.
pip<24.3
2 changes: 1 addition & 1 deletion requirements/edx/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -815,7 +815,7 @@ openedx-filters==2.0.1
# -r requirements/edx/kernel.in
# lti-consumer-xblock
# ora2
openedx-forum==0.3.4
openedx-forum==0.3.6
# via -r requirements/edx/kernel.in
openedx-learning==0.26.0
# via
Expand Down
2 changes: 1 addition & 1 deletion requirements/edx/development.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1374,7 +1374,7 @@ openedx-filters==2.0.1
# -r requirements/edx/testing.txt
# lti-consumer-xblock
# ora2
openedx-forum==0.3.4
openedx-forum==0.3.6
# via
# -r requirements/edx/doc.txt
# -r requirements/edx/testing.txt
Expand Down
2 changes: 1 addition & 1 deletion requirements/edx/doc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -986,7 +986,7 @@ openedx-filters==2.0.1
# -r requirements/edx/base.txt
# lti-consumer-xblock
# ora2
openedx-forum==0.3.4
openedx-forum==0.3.6
# via -r requirements/edx/base.txt
openedx-learning==0.26.0
# via
Expand Down
2 changes: 1 addition & 1 deletion requirements/edx/testing.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1044,7 +1044,7 @@ openedx-filters==2.0.1
# -r requirements/edx/base.txt
# lti-consumer-xblock
# ora2
openedx-forum==0.3.4
openedx-forum==0.3.6
# via -r requirements/edx/base.txt
openedx-learning==0.26.0
# via
Expand Down
4 changes: 1 addition & 3 deletions requirements/pip.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ wheel==0.45.1

# The following packages are considered to be unsafe in a requirements file:
pip==24.2
# via
# -c requirements/common_constraints.txt
# -r requirements/pip.in
# via -r requirements/pip.in
setuptools==79.0.0
# via -r requirements/pip.in
8 changes: 6 additions & 2 deletions xmodule/util/builtin_assets.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
"""
from pathlib import Path

import webpack_loader
from django.conf import settings
from django.core.exceptions import ImproperlyConfigured

Expand Down Expand Up @@ -44,6 +43,11 @@ def add_webpack_js_to_fragment(fragment, bundle_name):
"""
Add all JS webpack chunks to the supplied fragment.
"""
for chunk in webpack_loader.utils.get_files(bundle_name, None, 'DEFAULT'):
# Importing webpack_loader.utils at the top of the module causes an exception:
# OSError: Error reading webpack-stats.json.
# Are you sure webpack has generated the file and the path is correct?
# We are not quite sure why.
from webpack_loader.utils import get_files
for chunk in get_files(bundle_name, None, 'DEFAULT'):
if chunk['name'].endswith(('.js', '.js.gz')):
fragment.add_javascript_url(chunk['url'])
Loading