<commit_before>import React from 'react';
import styled from 'styled-components';
import { useAmp } from 'next/amp';
import { MDXProvider } from '@mdx-js/react';
import Meta from '~/components/meta';
import Header from '~/components/header/index';
import Paragraph from '~/components/paragraph';
import { Post as PostType } from '~/components/post-card/index';
import useScrollProgress from '~/components/use-scroll-progress';
import { Code, InlineCode } from '~/components/code';

const ScrollProgress = styled.progress.attrs({ max: 100, min: 0 })`
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 2;
  height: 3px;
  appearance: none;
  border: none;
  background: none;

  &::-webkit-progress-bar {
    background-color: transparent;
  }

  &::-webkit-progress-value {
    background-image: linear-gradient(135deg, #7fdbca 0%, #82aaff 100%);
  }

  &::-moz-progress-bar {
    background-image: linear-gradient(135deg, #7fdbca 0%, #82aaff 100%);
  }
`;

const PostWrap = styled.div`
  margin: 3rem auto 0 auto;
  max-width: 90rem;
  width: 95%;
  min-height: calc(100vh - 50rem);
  padding: 0 env(safe-area-inset-right) 0 env(safe-area-inset-left);
  padding: 0 constant(safe-area-inset-right) 0 constant(safe-area-inset-left);
`;

interface Props {
  children: React.ReactNode;
  meta: PostType;
}

const components = {
  code: Code,
  inlineCode: InlineCode,
  p: Paragraph,
};

const Post = ({ children, meta: { url, ...meta } }: Props) => {
  const isAmp = useAmp();
  const scrollProgress = useScrollProgress();
  return (
    <MDXProvider components={components}>
      <Meta {...meta} />
      <Header {...meta} />
      {!isAmp && <ScrollProgress value={scrollProgress} />}
      <PostWrap>{children}</PostWrap>
    </MDXProvider>
  );
};

export default Post;
<commit_msg>style: update post min height<commit_after>import React from 'react';
import styled from 'styled-components';
import { useAmp } from 'next/amp';
import { MDXProvider } from '@mdx-js/react';
import Meta from '~/components/meta';
import Header from '~/components/header/index';
import Paragraph from '~/components/paragraph';
import { Post as PostType } from '~/components/post-card/index';
import useScrollProgress from '~/components/use-scroll-progress';
import { Code, InlineCode } from '~/components/code';

const ScrollProgress = styled.progress.attrs({ max: 100, min: 0 })`
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 2;
  height: 3px;
  appearance: none;
  border: none;
  background: none;

  &::-webkit-progress-bar {
    background-color: transparent;
  }

  &::-webkit-progress-value {
    background-image: linear-gradient(135deg, #7fdbca 0%, #82aaff 100%);
  }

  &::-moz-progress-bar {
    background-image: linear-gradient(135deg, #7fdbca 0%, #82aaff 100%);
  }
`;

const PostWrap = styled.div`
  margin: 3rem auto;
  max-width: 90rem;
  width: 95%;
  min-height: calc(100vh - 64rem);
  padding: 0 env(safe-area-inset-right) 0 env(safe-area-inset-left);
  padding: 0 constant(safe-area-inset-right) 0 constant(safe-area-inset-left);
`;

interface Props {
  children: React.ReactNode;
  meta: PostType;
}

const components = {
  code: Code,
  inlineCode: InlineCode,
  p: Paragraph,
};

const Post = ({ children, meta: { url, ...meta } }: Props) => {
  const isAmp = useAmp();
  const scrollProgress = useScrollProgress();
  return (
    <MDXProvider components={components}>
      <Meta {...meta} />
      <Header {...meta} />
      {!isAmp && <ScrollProgress value={scrollProgress} />}
      <PostWrap>{children}</PostWrap>
    </MDXProvider>
  );
};

export default Post;

{'fraction_non_alphanumeric': 0.15932391244111943, 'fraction_numerical': 0.025214740925464118, 'mean_word_length': 3.7941567065073043, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 19, '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': '2855212', 'n_tokens_mistral': 1327, 'n_tokens_neox': 1211, 'n_words': 306}