Showing 451 of 1,081 total issues
Function measureHeights
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function measureHeights(editor, container) {
const containerRect = container.getBoundingClientRect();
let lastTargetDimensions = {top: 0, height: 0};
let lastRectBottom = 0;
Function Center
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function Center(props) {
return (
<div className={classNames(styles.root)}>
<div ref={props.contentAreaRef} />
Function updateAreaSelect
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
updateAreaSelect() {
var imageWidth = this.options.file.get('width');
var imageHeight = this.options.file.get('height');
this.ui.image.imgAreaSelect({
Function getMetaData
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
getMetaData: function () {
var self = this;
this.model.get('importer').getFilesMetaData().then(function (metaData) {
if (metaData) {
self.model.set('metaData', metaData);
Function constructor
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
constructor: function(options) {
var parent = options.parent;
var parentModel = options.parentModel;
this.autoConsolidatePositions = options.autoConsolidatePositions;
Function startEventPropagation
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function startEventPropagation(player, id) {
let playCallback = function() {
that.trigger('play', {audioFileId: id});
}
let pauseCallback = function() {
Method default_thumbnail_candidates
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def self.default_thumbnail_candidates
[
{
file_collection: 'image_files',
attribute: 'thumbnail_image_id'
Method thumbnail_candidates
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def thumbnail_candidates
[
{
file_collection: 'image_files',
attribute: 'thumbnail_image_id'
Function render
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
const page = this.props.page;
return (
<PageWrapper className={classNames({unplayed: !this.props.textHasBeenHidden}, 'hide_content_with_text')}>
Function configurationEditor
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
configurationEditor({entry, contentElement}) {
this.tab('general', function() {
this.input('image', FileInputView, {
collection: 'image_files',
fileSelectionHandler: 'contentElementConfiguration',
Function setup
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Slideshow.setup = function(options) {
function configurationsById(pages) {
return _.reduce(pages, function(memo, page) {
memo[page.id] = page.configuration;
return memo;
Function Waveform
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function Waveform(props) {
if (props.pageIsPrepared && props.mediaElementId) {
return (
<Measure whitelist={['height']}>
{ ({height}) =>
Function onRender
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
onRender() {
if (this.options.portraitFile) {
const tabsView = new TabsView({
translationKeyPrefixes: [`${i18nPrefix}.tabs`],
defaultTab: this.options.defaultTab
Function useChapters
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function useChapters() {
const chapters = useEntryStateCollectionItems('chapters');
return useMemo(() => {
const chapterSlugs = {};
Function useShortcutHandler
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export function useShortcutHandler(editor) {
return useCallback(event => {
if (!event.ctrlKey) {
return;
}
Function hooks
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const hooks = function(player, hooks) {
var originalPlay = player.play;
player.updateHooks = (newHooks) => {
hooks = newHooks;
Function onRender
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
onRender: function() {
var view = this;
var file = this.model.getReference(this.options.propertyName, this.options.filesCollection),
image = $('<img />').attr('src', file.getBackgroundPositioningImageUrl());
Function initialize
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
initialize: function(options) {
this.model = options.model;
this.typeName = options.typeName;
this.collectionName = options.collectionName;
this.topLevelType = options.topLevelType;
Function onRender
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
onRender: function() {
var view = this;
_(this.options.columns).each(function(column) {
this.ui.headRow.append(this.subview(new TableHeaderCellView({
Function show
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
show: function(text, position, options) {
options = options || {};
this.visible = true;
clearTimeout(this.timeout);