<commit_before>import React from "react"
import styled from "styled-components"
import { Subscribe } from "unstated"

import { FilterState } from "Apps/Search/FilterState"
import { Mediator } from "Artsy/SystemContext"
import { MobileActionSheet } from "../SearchResultsMobileActionSheet"
import { ColorFilter } from "./ColorFilter"
import { MediumFilter } from "./MediumFilter"
import { PriceRangeFilter } from "./PriceRangeFilter"
import { SizeRangeFilters } from "./SizeRangeFilters"
import { TimePeriodFilter } from "./TimePeriodFilter"
import { WaysToBuyFilter } from "./WaysToBuyFilter"

import {
  Box,
  Button,
  FilterIcon,
  Flex,
  Separator,
  Spacer,
  Toggle,
} from "@artsy/palette"
import { Media } from "Utils/Responsive"

export interface FilterContainerProps {
  user?: any
  mediator: Mediator
  mediums: Array<{ id: string; name: string }>
  timePeriods?: Array<{ name: string }>
  children?: (filters: FilterState) => JSX.Element
}

export interface FilterContainerState {
  showMobileActionSheet: boolean
}
export class FilterContainer extends React.Component<
  FilterContainerProps,
  FilterContainerState
> {
  state = {
    showMobileActionSheet: false,
  }

  hideMobileActionSheet = () => {
    this.setState({
      showMobileActionSheet: false,
    })<commit_msg>[Search] Ensure scrolling disabled on artwork grid while xs filter is open<commit_after>import React from "react"
import styled from "styled-components"
import { Subscribe } from "unstated"

import { FilterState } from "Apps/Search/FilterState"
import { Mediator } from "Artsy/SystemContext"
import { MobileActionSheet } from "../SearchResultsMobileActionSheet"
import { ColorFilter } from "./ColorFilter"
import { MediumFilter } from "./MediumFilter"
import { PriceRangeFilter } from "./PriceRangeFilter"
import { SizeRangeFilters } from "./SizeRangeFilters"
import { TimePeriodFilter } from "./TimePeriodFilter"
import { WaysToBuyFilter } from "./WaysToBuyFilter"

import {
  Box,
  Button,
  FilterIcon,
  Flex,
  Separator,
  Spacer,
  Toggle,
} from "@artsy/palette"
import { Media } from "Utils/Responsive"

export interface FilterContainerProps {
  user?: any
  mediator: Mediator
  mediums: Array<{ id: string; name: string }>
  timePeriods?: Array<{ name: string }>
  children?: (filters: FilterState) => JSX.Element
}

export interface FilterContainerState {
  showMobileActionSheet: boolean
}
export class FilterContainer extends React.Component<
  FilterContainerProps,
  FilterContainerState
> {
  state = {
    showMobileActionSheet: false,
  }

  componentDidMount() {
    this.updateBodyScrollBlock()
  }

  componentDidUpdate() {
    this.updateBodyScrollBlock()
  }

  updateBodyScrollBlock() {
    if (this.state.showMobileActionSheet) {
      document.body.style.overflowY = "hidden"
    } else {
      document.body.style.overflowY = "visible"
    }
  }

  hideMobileActionSheet = () => {
    this.setState({
      showMobileActionSheet: false,
    })
{'fraction_non_alphanumeric': 0.10650488709133805, 'fraction_numerical': 0.0, 'mean_word_length': 4.4659300184162065, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7394513', 'n_tokens_mistral': 882, 'n_tokens_neox': 860, 'n_words': 227}