diff --git a/app/soapbox/features/compose/editor/index.tsx b/app/soapbox/features/compose/editor/index.tsx index 0ffbded35..82b0cbae9 100644 --- a/app/soapbox/features/compose/editor/index.tsx +++ b/app/soapbox/features/compose/editor/index.tsx @@ -1,11 +1,9 @@ -/* -MIT License +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ import { AutoLinkPlugin, createLinkMatcherWithRegExp } from '@lexical/react/LexicalAutoLinkPlugin'; import { LexicalComposer, InitialConfigType } from '@lexical/react/LexicalComposer'; import { ContentEditable } from '@lexical/react/LexicalContentEditable'; diff --git a/app/soapbox/features/compose/editor/nodes/image-component.tsx b/app/soapbox/features/compose/editor/nodes/image-component.tsx index 654685919..c5d302a07 100644 --- a/app/soapbox/features/compose/editor/nodes/image-component.tsx +++ b/app/soapbox/features/compose/editor/nodes/image-component.tsx @@ -1,12 +1,9 @@ /** - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - * + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. */ - import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext'; import { useLexicalNodeSelection } from '@lexical/react/useLexicalNodeSelection'; import { mergeRegister } from '@lexical/utils'; diff --git a/app/soapbox/features/compose/editor/nodes/image-node.tsx b/app/soapbox/features/compose/editor/nodes/image-node.tsx index ab9fc0755..01bf9ad62 100644 --- a/app/soapbox/features/compose/editor/nodes/image-node.tsx +++ b/app/soapbox/features/compose/editor/nodes/image-node.tsx @@ -1,9 +1,7 @@ /** - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - * + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. */ import { $applyNodeReplacement, DecoratorNode } from 'lexical'; diff --git a/app/soapbox/features/compose/editor/nodes/index.ts b/app/soapbox/features/compose/editor/nodes/index.ts index 41448cf98..0357504d9 100644 --- a/app/soapbox/features/compose/editor/nodes/index.ts +++ b/app/soapbox/features/compose/editor/nodes/index.ts @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ import { CodeHighlightNode, CodeNode } from '@lexical/code'; import { HashtagNode } from '@lexical/hashtag'; diff --git a/app/soapbox/features/compose/editor/nodes/mention-node.tsx b/app/soapbox/features/compose/editor/nodes/mention-node.tsx index b3400da29..a559eda40 100644 --- a/app/soapbox/features/compose/editor/nodes/mention-node.tsx +++ b/app/soapbox/features/compose/editor/nodes/mention-node.tsx @@ -1,9 +1,7 @@ /** - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - * + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. */ import { addClassNamesToElement } from '@lexical/utils'; diff --git a/app/soapbox/features/compose/editor/plugins/autosuggest-plugin.tsx b/app/soapbox/features/compose/editor/plugins/autosuggest-plugin.tsx index c6db3284c..794742fc7 100644 --- a/app/soapbox/features/compose/editor/plugins/autosuggest-plugin.tsx +++ b/app/soapbox/features/compose/editor/plugins/autosuggest-plugin.tsx @@ -1,9 +1,7 @@ /** - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - * + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. */ import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext'; diff --git a/app/soapbox/features/compose/editor/plugins/floating-block-type-toolbar-plugin.tsx b/app/soapbox/features/compose/editor/plugins/floating-block-type-toolbar-plugin.tsx index 8f5a951c1..67fab475b 100644 --- a/app/soapbox/features/compose/editor/plugins/floating-block-type-toolbar-plugin.tsx +++ b/app/soapbox/features/compose/editor/plugins/floating-block-type-toolbar-plugin.tsx @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext'; import { $createHorizontalRuleNode } from '@lexical/react/LexicalHorizontalRuleNode'; diff --git a/app/soapbox/features/compose/editor/plugins/floating-link-editor-plugin.tsx b/app/soapbox/features/compose/editor/plugins/floating-link-editor-plugin.tsx index c95e9739a..2b0d3ae27 100644 --- a/app/soapbox/features/compose/editor/plugins/floating-link-editor-plugin.tsx +++ b/app/soapbox/features/compose/editor/plugins/floating-link-editor-plugin.tsx @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ import { $isAutoLinkNode, $isLinkNode, TOGGLE_LINK_COMMAND } from '@lexical/link'; import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext'; diff --git a/app/soapbox/features/compose/editor/plugins/floating-text-format-toolbar-plugin.tsx b/app/soapbox/features/compose/editor/plugins/floating-text-format-toolbar-plugin.tsx index 4e554bbae..53c52fe4b 100644 --- a/app/soapbox/features/compose/editor/plugins/floating-text-format-toolbar-plugin.tsx +++ b/app/soapbox/features/compose/editor/plugins/floating-text-format-toolbar-plugin.tsx @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ import { $createCodeNode, $isCodeHighlightNode } from '@lexical/code'; import { $isLinkNode, TOGGLE_LINK_COMMAND } from '@lexical/link'; diff --git a/app/soapbox/features/compose/editor/plugins/link-plugin.tsx b/app/soapbox/features/compose/editor/plugins/link-plugin.tsx index c892a294a..07f24f447 100644 --- a/app/soapbox/features/compose/editor/plugins/link-plugin.tsx +++ b/app/soapbox/features/compose/editor/plugins/link-plugin.tsx @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ import { LinkPlugin as LexicalLinkPlugin } from '@lexical/react/LexicalLinkPlugin'; import * as React from 'react'; diff --git a/app/soapbox/features/compose/editor/plugins/mention-plugin.tsx b/app/soapbox/features/compose/editor/plugins/mention-plugin.tsx index f2746e3af..0465a6a75 100644 --- a/app/soapbox/features/compose/editor/plugins/mention-plugin.tsx +++ b/app/soapbox/features/compose/editor/plugins/mention-plugin.tsx @@ -1,9 +1,7 @@ /** - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - * + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. */ import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext'; diff --git a/app/soapbox/features/compose/editor/utils/get-dom-range-rect.ts b/app/soapbox/features/compose/editor/utils/get-dom-range-rect.ts index bf9c6b8c3..4f8d9eb0d 100644 --- a/app/soapbox/features/compose/editor/utils/get-dom-range-rect.ts +++ b/app/soapbox/features/compose/editor/utils/get-dom-range-rect.ts @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ /* eslint-disable eqeqeq */ diff --git a/app/soapbox/features/compose/editor/utils/get-selected-node.ts b/app/soapbox/features/compose/editor/utils/get-selected-node.ts index c4522c12c..992eafa0a 100644 --- a/app/soapbox/features/compose/editor/utils/get-selected-node.ts +++ b/app/soapbox/features/compose/editor/utils/get-selected-node.ts @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ import { $isAtNodeEnd } from '@lexical/selection'; import { ElementNode, RangeSelection, TextNode } from 'lexical'; diff --git a/app/soapbox/features/compose/editor/utils/point.ts b/app/soapbox/features/compose/editor/utils/point.ts index 4cd951c82..f8de0f168 100644 --- a/app/soapbox/features/compose/editor/utils/point.ts +++ b/app/soapbox/features/compose/editor/utils/point.ts @@ -1,10 +1,9 @@ /** - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - * + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. */ + class Point { private readonly _x: number; diff --git a/app/soapbox/features/compose/editor/utils/rect.ts b/app/soapbox/features/compose/editor/utils/rect.ts index 1a7f4b769..901f30411 100644 --- a/app/soapbox/features/compose/editor/utils/rect.ts +++ b/app/soapbox/features/compose/editor/utils/rect.ts @@ -1,11 +1,10 @@ /* eslint-disable no-dupe-class-members */ /** - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - * + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. */ + import { isPoint, Point } from './point'; type ContainsPointReturn = { diff --git a/app/soapbox/features/compose/editor/utils/set-floating-elem-position.ts b/app/soapbox/features/compose/editor/utils/set-floating-elem-position.ts index 64ede997e..e9271e3dd 100644 --- a/app/soapbox/features/compose/editor/utils/set-floating-elem-position.ts +++ b/app/soapbox/features/compose/editor/utils/set-floating-elem-position.ts @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ const VERTICAL_GAP = 10; const HORIZONTAL_OFFSET = 5; diff --git a/app/soapbox/features/compose/editor/utils/url.ts b/app/soapbox/features/compose/editor/utils/url.ts index 3d0192d07..f10af4e5c 100644 --- a/app/soapbox/features/compose/editor/utils/url.ts +++ b/app/soapbox/features/compose/editor/utils/url.ts @@ -1,11 +1,8 @@ -/* -MIT License - -Copyright (c) Meta Platforms, Inc. and affiliates. - -This source code is licensed under the MIT license found in the -LICENSE file in the /app/soapbox/features/compose/editor directory. -*/ +/** + * This source code is derived from code from Meta Platforms, Inc. + * and affiliates, licensed under the MIT license located in the + * LICENSE file in the /app/soapbox/features/compose/editor directory. + */ export const sanitizeUrl = (url: string): string => { /** A pattern that matches safe URLs. */