Path: blob/master/src/packages/frontend/customize/terms-of-service.tsx
1496 views
/*1* This file is part of CoCalc: Copyright © 2020 Sagemath, Inc.2* License: MS-RSL – see LICENSE.md for details3*/45import { useTypedRedux } from "../app-framework";6import { A } from "../components";78export const TermsOfService: React.FC<{ style?: React.CSSProperties }> = ({9style,10}) => {11const terms_of_service = useTypedRedux("customize", "terms_of_service");12const terms_of_service_url = useTypedRedux("customize", "terms_of_service_url");13if (terms_of_service?.length > 0) {14return (15<div16style={style}17dangerouslySetInnerHTML={{ __html: terms_of_service }}18></div>19);20} else if (terms_of_service_url?.length > 0) {21// only used in the context of signing up, hence that phrase...22return (23<div style={style}>24I agree to the <A href={terms_of_service_url}>Terms of Service</A>.25</div>26);27} else {28return <></>;29}30};313233