fluttercommunity / fluttercommunity/flutter_webview_plugin

WebviewScaffold rendered Outside the Container

Đang mở
#282 3 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Java
Star
1.5k
Fork
938
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Hi i need help: **Webviewscaffold** rendered outside the **Container**
I'm trying to load string text into a **WebviewScaffold**, but the webview is outside the container :
![pic](https://user-images.githubusercontent.com/10370643/50445240-2dd60d00-0905-11e9-80ec-e6eab3138784.jpg)

I tested with Text widget it worked well

```
_getDescription(description) {
return new Container(
child:
//new Text(description),
new WebviewScaffold(
url: new Uri.dataFromString(description, mimeType: 'text/html',encoding: utf8).toString()),
width: double.infinity,
margin: new EdgeInsets.only(top: 10.0),
height: 80,

);
}
```
the full Class:

```
child: new ListView(
children: [
new Hero(
tag: _title,
child: _getImageNetwork(Functions.getImgResizeUrl(_img,250,''))
),
_getBody(_title,_date,_description,_origin,context),
],
),

Widget _getBody(tittle,date,description,origin,context){

return new Container(
margin: new EdgeInsets.all(15.0),
child: new Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
_getTittle(tittle), //Text Widget
_getDate(date,origin), //Text Widget
_getDescription(description),
_getAntLink(),
_getLink(_link,context)
],
),
);
}
```
there is a warning in the Flutter WebView Plugin Docs :

> Warning: The webview is not integrated in the widget tree, it is a native view on top of the flutter view. you won't be able to use snackbars, dialogs ...

is this real reason of the problem?

Please Help!!

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Hướng nghiên cứu

Tái hiện _getDescription WebviewScaffold bên trong ListView và Container được hiển thị trong issue, đồng thời so sánh với Text widget đang hoạt động. Xem lại cảnh báo trong tài liệu plugin rằng native view chưa được tích hợp vào widget tree của Flutter. Được xem là hoàn tất khi xác định liệu việc định vị quan sát được có phải là một hạn chế cố hữu hay không, đồng thời ghi lại hành vi được hỗ trợ hoặc một bản sửa lỗi cụ thể.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
dart, flutter
Lĩnh vực
mobile-dev
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Cần làm rõ
Mức phù hợp với người mới
20/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.