Add stride/chunking to `TextClassificationPipeline`
# What does this PR do?

Adds sliding window/chunking functionality to `TextClassificationPipeline` (similar to what #21771 did for `TokenClassificationPipeline`).

## Before submitting
- [ ] This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
- [x] Did you read the [contributor guideline](https://github.com/huggingface/transformers/blob/main/CONTRIBUTING.md#start-contributing-pull-requests),
      Pull Request section?
- [ ] Was this discussed/approved via a Github issue or the [forum](https://discuss.huggingface.co/)? Please add a link
      to it if that's the case.
- [ ] Did you make sure to update the documentation with your changes? Here are the
      [documentation guidelines](https://github.com/huggingface/transformers/tree/main/docs), and
      [here are tips on formatting docstrings](https://github.com/huggingface/transformers/tree/main/docs#writing-source-documentation).
- [x] Did you write any new necessary tests?


## Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.

@Narsil

I happened to implement this for another project, so I went straight to implementing a PR here (skipping opening an issue) to see if this would be a desirable feature for HF. I realized after opening this PR that I haven't finished updating the docstrings where appropriate.

I could also use some guidance on when & where to return the result as a list vs. a list-of-lists; I'll admit I worked out [this section of code](https://github.com/huggingface/transformers/blob/52253ed1b1722a8e60e2df29ce0b1339dce07d9f/src/transformers/pipelines/text_classification.py#L222) mainly through trial-and-error with the existing test suite--not an ideal way to program.

Much of this code is copied/adapted from `TokenClassificationPipeline`. It looks like the changes also broke the legacy functionality of text pairs as shown in tests such as [`tests/models/bert/test_modeling_tf_bert.py::TFBertModelTest::test_pipeline_text_classification`](https://app.circleci.com/pipelines/github/huggingface/transformers/66591/workflows/85501b27-19f8-4dfe-a24e-242592463a89/jobs/829459); I think I can fix that if this new functionality turns out to be something the HuggingFace team wants to add.<|||||>The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/transformers/pr_24312). All of your documentation changes will be reflected on that endpoint.<|||||>This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.

Please note that issues that do not follow the [contributing guidelines](https://github.com/huggingface/transformers/blob/main/CONTRIBUTING.md) are likely to be ignored.