-
Notifications
You must be signed in to change notification settings - Fork 0
feat: OpenCraft sandbox footer. #6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: sandbox-footer
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
// eslint-disable-next-line no-unused-vars", | ||
|
||
import { DIRECT_PLUGIN, PLUGIN_OPERATIONS } from '@openedx/frontend-plugin-framework'; | ||
|
||
const OpenCraftFooter = () => ( | ||
<> | ||
<footer className="opencraft-footer py-5 px-5"> | ||
<div className={'d-flex pb-3 flex-column flex-md-row'}> | ||
<div className={"text-center"}> | ||
<img alt="OpenCraft Logo" className="opencraft-logo pt-1" src="https://opencraft.com/wp-content/uploads/opencraft-logo.png"/> | ||
</div> | ||
<div className={"pr-5 d-none d-md-block"}></div> | ||
<div className={"pt-3 d-block d-md-none"}></div> | ||
<div className={"align-self-top text-center text-md-left"}> | ||
Hosted by <a href="https://opencraft.com/">OpenCraft.</a><br /> | ||
A verified Open edX® partner. | ||
</div> | ||
</div> | ||
<hr /> | ||
<div className={"text-center text-md-left"}><small>© OpenCraft 2025 | edX and Open edX® are trademarks of edX Inc</small></div> | ||
</footer> | ||
</> | ||
) | ||
|
||
const config = { | ||
ACCESS_TOKEN_COOKIE_NAME: 'edx-jwt-cookie-header-payload', | ||
ACCOUNT_PROFILE_URL: "http://local.openedx.io:1995", | ||
ACCOUNT_SETTINGS_URL: "http://local.openedx.io:1997", | ||
BASE_URL: "local.openedx.io:8080", | ||
CREDENTIALS_BASE_URL: "http://local.openedx.io:18150", | ||
CSRF_TOKEN_API_PATH: "/csrf/api/v1/token", | ||
ECOMMERCE_BASE_URL: "http://local.openedx.io:18130", | ||
LANGUAGE_PREFERENCE_COOKIE_NAME: "openedx-language-preference", | ||
LMS_BASE_URL: "http://local.openedx.io:8000", | ||
STUDIO_BASE_URL: "http://studio.local.openedx.io:8001", | ||
LOGIN_URL: "http://local.openedx.io:8000/login", | ||
LOGOUT_URL: "http://local.openedx.io:8000/logout", | ||
MARKETING_SITE_BASE_URL: "http://local.openedx.io:8000", | ||
ORDER_HISTORY_URL: "localhost:1996/orders", | ||
REFRESH_ACCESS_TOKEN_ENDPOINT: "http://local.openedx.io:8000/login_refresh", | ||
SEGMENT_KEY: "null", | ||
SITE_NAME: "Open edX", | ||
USER_INFO_COOKIE_NAME: "edx-user-info", | ||
LOGO_URL: "/brand-openedx/logo.svg", | ||
LOGO_TRADEMARK_URL: "/brand-openedx/logo-trademark.svg", | ||
LOGO_WHITE_URL: "/brand-openedx/logo-white.svg", | ||
FAVICON_URL: "https://edx-cdn.org/v3/default/favicon.ico", | ||
pluginSlots: { | ||
'org.openedx.frontend.layout.footer.v1': { | ||
plugins: [ | ||
{ | ||
// Hide the default footer | ||
op: PLUGIN_OPERATIONS.Hide, | ||
widgetId: 'default_contents', | ||
}, | ||
{ | ||
// Insert a custom footer | ||
op: PLUGIN_OPERATIONS.Insert, | ||
widget: { | ||
id: 'custom_footer', | ||
type: DIRECT_PLUGIN, | ||
RenderWidget: OpenCraftFooter, | ||
}, | ||
}, | ||
] | ||
} | ||
}, | ||
}; | ||
|
||
export default config; |
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this was accidentally committed. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
$opencraft-green: #0F1F24 !default; | ||
$footer-text-color: #ffffff !default; | ||
$footer-link-hover-color: #8CAEB5 !default; | ||
$opencraft-footer-link-color: #5EFFC9 !default; | ||
$opencraft-accent: #203D44 !default; | ||
|
||
Comment on lines
+1
to
+6
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think colors should be hardcoded here. This should be moved to the theme. |
||
.opencraft-footer { | ||
background-color: $opencraft-green; | ||
color: $footer-text-color; | ||
font-size: 16px; | ||
.opencraft-logo { | ||
height: 60px; | ||
} | ||
hr { | ||
border-color: $opencraft-accent; | ||
} | ||
a { | ||
color: $opencraft-footer-link-color; | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be in separate component file and imported here.