gitweixin
  • 首页
  • 小程序代码
    • 资讯读书
    • 工具类
    • O2O
    • 地图定位
    • 社交
    • 行业软件
    • 电商类
    • 互联网类
    • 企业类
    • UI控件
  • 大数据开发
    • Hadoop
    • Spark
    • Hbase
    • Elasticsearch
    • Kafka
    • Flink
    • 数据仓库
    • 数据挖掘
    • flume
    • Kafka
    • Hive
    • shardingsphere
    • solr
  • 开发博客
    • Android
    • php
    • python
    • 运维
    • 技术架构
    • 数据库
  • 程序员网赚
  • bug清单
  • 量化投资
  • 在线查询工具
    • 去行号
    • 在线时间戳转换工具
    • 免费图片批量修改尺寸在线工具
    • SVG转JPG在线工具

学日语五十音微信小程序代码

精品微信小程序开发门户,代码全部亲测可用

  • 首页   /  
  • 作者: east
  • ( 页面60 )
资讯读书 3月 25,2021

学日语五十音微信小程序代码

日语五十音,就像学中文的学拼音,是十分基础的。



//const Util = require('../../utils/util.js')
const Data = require('../../data.js')
Page({
  //data 将会以 JSON 的形式由逻辑层传至渲染层,所以其数据必须是可以转成 JSON 的格式:字符串,数字,布尔值,对象,数组。
  //此处 forfoot 用数据徐循环则没什么意思了 无法绑定 并 调用回调 data中也无法存function;
  data: {
    minHeight:'',
    mojiList:[],
    // fortest:'test',
    hiraganaShow:true,
    //无法操作dom 都需要靠data绑定
    changeKANAText:'あ',
    tabnow:'seionn',
    sannbunn:false
    // ,
    // forfoot:{
    //   tabBarList:[
    //     {
    //       text:'假名',
    //       tabCbName:'changeKANA'
    //       // ,
    //       // cbfn:function(Page){
    //       //     Page.setData({
    //       //       fortest: 'changeKANA'
    //       //     })
    //       // }
    //     },
    //     {
    //       text:'清音',
    //       tabCbName:'toSEIONN'
    //       // ,
    //       // cbfn:function(Page){
    //       //     Page.setData({
    //       //       fortest: 'toSEIONN'
    //       //     })
    //       // }
    //     },
    //     {
    //       text:'浊音',
    //       tabCbName:'toDAKUONN'
    //       // ,
    //       // cbfn:function(Page){
    //       //     Page.setData({
    //       //       fortest: 'toDAKUONN'
    //       //     })
    //       // }
    //     },
    //     {
    //       text:'拗音',
    //       tabCbName:'toYOUONN'
    //       // ,
    //       // cbfn:function(Page){
    //       //     Page.setData({
    //       //       fortest: 'toYOUONN'
    //       //     })
    //       // }
    //     }
    //   ]
    // }
  },
  onLoad: function () {
    let that = this;
    //获取系统信息
    wx.getSystemInfo({
      success: function(res) {
        that.setData({
          minHeight: res.windowHeight
        })
      }
    })
    that.setData({
      mojiList: Data.seionn
    })
    // for(let i of that.data.forfoot.tabBarList){
    //   console.log(i);
    //   Util.addEventHandleCb(that,i['tabCbName'],i['cbfn']);
    // }
  },
  //eventHandle  需在相应的Page定义中写上相应的事件处理函数...mdzz
  changeKANA(e){
    //e 不知道能咋用
    let show = this.data.hiraganaShow;
    this.setData({
      hiraganaShow: !show
    })  
    !show?this.setData({changeKANAText: 'あ'}):this.setData({changeKANAText: 'ア'})
  },
  toSEIONN(){
    this.setData({
      mojiList: Data.seionn,
      tabnow:'seionn',
      sannbunn:false
    })
  },
  toDAKUONN(){
    this.setData({
      mojiList: Data.dakuonn,
      tabnow:'dakuonn',
      sannbunn:false
    })
  },
  toYOUONN(){
    this.setData({
      mojiList: Data.youonn,
      tabnow:'youonn',
      sannbunn:true
    })
  }
})

下载地址:工程代码

作者 east
工具类 3月 24,2021

To do 清单列表微信小程序代码

在现在社会,注意力经常被各种电子屏分散。为了高效学习,可以把任务清单分成1个个To do清单列表,集中注意力完成一个个清单,然后在小程序打勾完成。而且对小程序的清单列表还设置了密码,防止秘密内容被别人看到。

下载地址:工程代码

作者 east
资讯读书 3月 21,2021

仿今日头条move css微信小程序代码

仿照今天头条,对栏目可以动态进行设置,并且有摇动,移动等动画效果。动画效果用的是css 的move元素。

下载地址:工程代码

作者 east
互联网类 3月 21,2021

LOL战绩查询微信小程序代码

这是一款功能齐全的微信小程序, 显示最新的英雄联盟视频; 可以模糊查询游戏,雷达图形统计游戏能力,统计最近常用的英雄。

下载地址:工程代码

作者 east
资讯读书 3月 20,2021

仿微信读书微信小程序

读书类的小程序是很常用的应用,而且很方便在微信群分享。

小程序的功能是图文混排的列表,用户可以搜索书单。点击列表进入书的详细页。

<view class="container">
    <loading hidden="{{hidden}}">加载中...</loading>
    <view class="book-detail">
        <image class="book-image" style="width:300px;height:393px;display:block;margin:10px auto;background-color: #eeeeee;" scaleToFill  src="{{info.Image}}"></image>
        <view class="books-item-txt">
            <view class="txt-title">
                <text>{{info.Title}}</text>
            </view>
            <view>
                <text style="color:#aaa;clear:both;">Published in {{info.Year}}</text>
            </view>
            <view class="txt-source">
                <text>{{info.SubTitle}}</text>
            </view>
            <view class="books-item-author">
                <image class="avatar" style="width:20px;height:20px;" aspectFit src="https://cdn1.iconfinder.com/data/icons/user-pictures/100/unknown-128.png"></image>
                <view class="author-txt">
                    <text style="margin-top:5px;">{{info.Author}}</text>
                    
                </view>
            </view>
        </view>

        <navigator class="book-download" url="{{info.Download}}">
            <icon type="download" size="30" class="download-icon"/>
            <text>Download This Book</text>
        </navigator>
    </view>
</view>

var API = require(‘../../utils/api.js’);
//获取应用实例
Page({
data: {
info:{},
hidden:false
},
onLoad: function (e) {
console.log(e)
this.fetchBookData(e.id)
},
//获取微信精选
fetchBookData: function(id){
let self = this;
wx.request({
url: API.ebookinfo(id),
success: function (res) {
self.setData({
info:res.data,
hidden: true
})
}
})
}
})

下载地址:工程

作者 east
Java 3月 16,2021

空间地理算法工具类

空间地理,常常需要计算2个地址是否是同个地址,2个坐标之间的直线距离。下面把这些常用算法进行封装。 2个地址是否是同个地址 的相似度算法,采用 余弦相似度用向量空间中两个向量夹角的余弦值作为衡量两个个体间差异的大小。相比距离度量,余弦相似度更加注重两个向量在方向上的差异,而非距离或长度上。 

public final class ScoreUtil {
    private static Logger log = LoggerFactory.getLogger(ScoreUtil.class);

    /** 乡镇附属词 */
    private static final String WORD_TYPE_4 = "乡,镇,街道办事处,街道办,街道";

    /** 社区居委附属词 */
    private static final String WORD_TYPE_5 = "社区,社区居民委员会,村民委员会,社区居村委,社区居委,居村委,居委会,村委会,委员会,居委,村委,委会,村";

    /** 路附属词 */
    private static final String WORD_TYPE_6 = "道路,路,大街,街,巷";

    /** 自定义地址唯一组合 */
    private static final String[] UNION_SIMILAR = { "1&2&4&6", "1&3&6", "1&3" };

    /**
     * 
     */
    private ScoreUtil() {
    }

    /**
     * 计算两个地址的相似度
     * 
     * @param sourceAddr 源地址
     * @param standAddr 标准地址
     * @return
     * @throws Exception
     */
    public static long score(String sourceAddr, String standAddr) throws Exception {
        Map<Integer, String> sourceWords = WordSolrUtil.splitAddressWordNames(sourceAddr);
        Map<Integer, String> standWords = WordSolrUtil.splitAddressWordNames(standAddr);
        if (standWords.size() == 0 || sourceWords.size() == 0) {
            return 0L;
        }
        Integer sourceWordMaxType = Collections.max(sourceWords.keySet());
        Integer standWordMaxType = Collections.max(standWords.keySet());
        String sourceWordStr = null;
        String standWordStr = null;
        // 命中的词类型组合
        StringBuilder matchType = new StringBuilder();
        for (int i = (standWordMaxType > sourceWordMaxType ? standWordMaxType : sourceWordMaxType); i >= 1; i--) {
            sourceWordStr = sourceWords.get(i);
            standWordStr = standWords.get(i);
            if (i == 4) {
                if (StringUtils.isNotBlank(sourceWordStr)) {
                    sourceWords.put(i, sourceWordStr.replaceFirst("[" + WORD_TYPE_4 + "]$", "") + "乡镇");
                }
                if (StringUtils.isNotBlank(standWordStr)) {
                    standWords.put(i, standWordStr.replaceFirst("[" + WORD_TYPE_4 + "]$", "") + "乡镇");
                }
            } else if (i == 5) {
                if (StringUtils.isNotBlank(sourceWordStr)) {
                    sourceWords.put(i, sourceWordStr.replaceAll("[" + WORD_TYPE_5 + "]", "") + "居村委");
                }
                if (StringUtils.isNotBlank(standWordStr)) {
                    standWords.put(i, standWordStr.replaceAll("[" + WORD_TYPE_5 + "]", "") + "居村委");
                }
            } else if (i == 6) {
                if (StringUtils.isNotBlank(sourceWordStr)) {
                    sourceWords.put(i, sourceWordStr.replaceFirst("[" + WORD_TYPE_6 + "]$", "") + "大道");
                }
                if (StringUtils.isNotBlank(standWordStr)) {
                    standWords.put(i, standWordStr.replaceFirst("[" + WORD_TYPE_6 + "]$", "") + "大道");
                }
            }

            // 字符串相似度大于0.9,则标记为命中
            if (strSimilarMatch(sourceWords.get(i), standWords.get(i)) >= 0.9) {
                matchType.append(i).append("&");
            }
        }

        // 用于比较的地址字符串
        StringBuilder sourceAddrCompareStr = new StringBuilder();
        StringBuilder standAddrCompareStr = new StringBuilder();
        filterAddrToEquivalent(sourceWords, standWords, sourceWordMaxType, standWordMaxType, matchType,
                sourceAddrCompareStr, standAddrCompareStr);
        log.debug("源地址过滤后:" + sourceAddrCompareStr.toString());
        log.debug("标地址过滤后:" + standAddrCompareStr.toString());

        return Math.round(linearSpaceVectorMacth(sourceAddrCompareStr.toString(), standAddrCompareStr.toString()));
    }

    /**
     * 根据配置信息及别名过滤两个地址为等价地址
     * 
     * @param sourceWords
     * @param standWords
     * @param sourceWordMaxType
     * @param standWordMaxType
     * @param matchType
     * @param sourceAddrCompareStr
     * @param standAddrCompareStr
     */
    private static void filterAddrToEquivalent(Map<Integer, String> sourceWords, Map<Integer, String> standWords,
            Integer sourceWordMaxType, Integer standWordMaxType, StringBuilder matchType,
            StringBuilder sourceAddrCompareStr, StringBuilder standAddrCompareStr) {
        // 命中的词
        String[] matchedType = matchType.toString().contains("&") ? matchType.toString().split("&", 0) : new String[0];
        Arrays.sort(matchedType, new Comparator<String>() {

            @Override
            public int compare(String o1, String o2) {
                if (StringUtils.isBlank(o1)) {
                    return 1;
                }
                if (StringUtils.isBlank(o2)) {
                    return -1;
                }
                if (o1.equals(o2)) {
                    return 0;
                }
                return Integer.parseInt(o1) > Integer.parseInt(o2) ? 1 : -1;
            }
        });

        // 根据配置,移除可忽略的词
        for (int i = 0; i < UNION_SIMILAR.length; i++) {
            boolean isMatchedWithConfig = true;
            if (UNION_SIMILAR[i].split("&").length >= matchedType.length) {
                // 判断命中的词组是否与配置指定的一致
                for (String type : matchedType) {
                    if (StringUtils.isNotBlank(type) && Arrays.binarySearch(UNION_SIMILAR[i].split("&"), type) < 0) {
                        isMatchedWithConfig = false;
                        break;
                    }
                }

            } else {
                for (String type : UNION_SIMILAR[i].split("&")) {
                    if (StringUtils.isNotBlank(type) && Arrays.binarySearch(matchedType, type) < 0) {
                        isMatchedWithConfig = false;
                        break;
                    }
                }
                if (isMatchedWithConfig) {
                    matchedType = UNION_SIMILAR[i].split("&");
                }
            }

            if (isMatchedWithConfig && matchedType.length > 0) {
                // 补上缺省的词
                for (int j = Integer.parseInt(matchedType[0]); j <= Integer
                        .parseInt(matchedType[matchedType.length - 1]); j++) {
                    if (Arrays.binarySearch(matchedType, String.valueOf(j)) < 0) {
                        if (sourceWords.keySet().contains(j)) {
                            standWords.put(j, sourceWords.get(j));
                        } else if (standWords.keySet().contains(j)) {
                            sourceWords.put(j, standWords.get(j));
                        }
                    }
                }
            }
        }

        // 组装地址词组为字符串信息
        for (int i = 1; i <= (standWordMaxType > sourceWordMaxType ? standWordMaxType : sourceWordMaxType); i++) {
            sourceAddrCompareStr.append(StringUtils.trimToEmpty(sourceWords.get(i)));
            standAddrCompareStr.append(StringUtils.trimToEmpty(standWords.get(i)));
        }
    }

    /**
     * 线性空间几何
     * 
     * @param source
     * @param target
     * @return
     */
    private static double linearSpaceVectorMacth(String source, String target) {
        Set<Character> set = new HashSet<Character>();
        for (char c : source.toCharArray()) {
            set.add(c);
        }
        for (char c : target.toCharArray()) {
            set.add(c);
        }
        Character[] targetA = set.toArray(new Character[] {});
        int[] sourceArg = parseAddrToSpaceVector(targetA, source);
        int[] targetArg = parseAddrToSpaceVector(targetA, target);
        return cos(sourceArg, targetArg) * 100;
    }

    /**
     * 计算空间向量夹角cos值
     * 
     * @param point1
     * @param point2
     * @return
     */
    private static double cos(int[] point1, int[] point2) {
        int count = 0;
        for (int i = 0; i < point1.length; i++) {
            count += point1[i] * point2[i];
        }

        double a1 = 0.0;
        for (int i = 0; i < point1.length; i++) {
            a1 += point1[i] * point1[i];
        }
        a1 = Math.sqrt(a1);

        double a2 = 0.0;
        for (int i = 0; i < point2.length; i++) {
            a2 += point2[i] * point2[i];
        }
        a2 = Math.sqrt(a2);

        return count / (a1 * a2);
    }

    /**
     * 解析地址为空间向量坐标
     * 
     * @param tag
     * @param str
     * @return
     */
    private static int[] parseAddrToSpaceVector(Character[] tag, String str) {
        int[] rs = new int[tag.length];
        int count = 0;
        int i = 0;
        for (char t : tag) {
            count = 0;
            for (char c : str.toCharArray()) {
                if (t == c) {
                    count++;
                }
            }
            rs[i] = count;
            i++;
        }
        return rs;
    }

    /**
     * 字符串相似度匹配
     * 
     * @param compare
     * @param to
     * @return
     */
    public static double strSimilarMatch(String compare, String to) {
        if (StringUtils.isBlank(compare) || StringUtils.isBlank(to)) {
            return 0;
        }
        // 字符串相似度比较
        int len1 = compare.length();
        int len2 = to.length();

        int[][] dif = new int[len1 + 1][len2 + 1];
        for (int a = 0; a <= len1; a++) {
            dif[a][0] = a;
        }
        for (int a = 0; a <= len2; a++) {
            dif[0][a] = a;
        }

        int temp;
        for (int i = 1; i <= len1; i++) {
            for (int j = 1; j <= len2; j++) {
                if (compare.charAt(i - 1) == to.charAt(j - 1)) {
                    temp = 0;
                } else {
                    temp = 1;
                }
                dif[i][j] = min(dif[i - 1][j - 1] + temp, dif[i][j - 1] + 1, dif[i - 1][j] + 1);
            }
        }
        return 1 - (double) dif[len1][len2] / Math.max(compare.length(), to.length());
    }

    /**
     * 查找集合最小值
     * 
     * @param is
     * @return
     */
    private static int min(int... is) {
        int min = Integer.MAX_VALUE;
        for (int i : is) {
            if (min > i) {
                min = i;
            }
        }
        return min;
    }
}
作者 east
互联网类 3月 15,2021

仿dribbble设计社区小程序代码

dribble是一个艺术作品的交流网站,通过本小程序,可以学习到精美的布局,如何更好进行图文布局。可以流式看多个设计师的作品,关注点赞。

const { request, api, filterHtml, dateFormat, addCommas } = require('../../utils/util.js');

var app = getApp();

Page({
	data: {
		windowWidth: 0,
		windowHeight: 0,
		shotWidth: 0,
		shotHeight: 0,

    isShowLoading: true,
		designers: [],
		shots: {},
		pageIndex: 1
	},
	scroll: function(e){
		let { detail, currentTarget } = e;
		console.log('scroll:' ,e, detail.scrollLeft);

		let obj = {
			designers: this.data.designers
		};
		obj['designers'][currentTarget.dataset.index]['isScrolled'] = detail.scrollLeft > 0;

		this.setData(obj)
	},
	scrolltoupper: function(e) {
		console.log('scrolltoupper',e)
	},
	scrolltolower: function(e) {
		let { userid } = e.currentTarget.dataset;
		let { page } = this.data.shots[userid];

		this.getDesignerShots(userid, page);
	},
	/* 
	 * 获取单个设计师的 shots
	 *
	 * @param  {number} user_id   用户id
	 * @param  {number} page      页码
	*/
	getDesignerShots: function(user_id, page = 2) {
		request({
			url: api.getDesignerShots,
			data: {
				user_id,
				page
			}
		})
		.then(res => {
			console.log('[get designer shots]: ', res.data)

			let obj = {
				shots: this.data.shots
			};
			let data = res.data && res.data[0];
			// shots
			obj.shots[user_id] = {
				shots: obj.shots[user_id].shots.concat(data.shots || []),
				page: page + 1,
			};

			this.setData(obj);
		})
	},
	/* 
	 * 获取多个设计师的 shots
	 *
	 * @param  {array} ids  用户数组id
	*/
	getDesignersShots: function(ids) {
		console.log('[get designers shots]: ', ids);

    wx.request({
      	url: api.getDesignersShots(ids),
      	success: res => {
	        if (res.statusCode === 200){
						console.log('[get designers shots]: ', res);

	        	let { data } = res;
	        	if (data.length > 0) {
		        	let { shots } = this.data;

	        		for (d of data) {
	        			shots[d.user_id] = {
	        				shots: d.shots,
	        				page: 2 // 当前函数已经获取到了第一页,接下来获取要从第二页开始
	        			};
	        		}

	  	      	this.setData({
		        		shots
	    	    	});

	        	}

	        }
      	}
    })
	},
	/* 
	 * 获取设计师列表
	 *
	 * @param  {number} page      页码
	*/
	getDesigners: function(page){

		let _page = page || 1;

		this.setData({
			isShowLoading: true,
		})

		request({
			url: api.getDesigners,
			data: {
				page: _page
			}
		})
		.then(res => {
			let obj = {
				isShowLoading: false,
				designers: this.data.designers
			};

			let { datas } = res.data;
			if (datas.length > 0) {
				let ids = datas.map(d => d.id); // return -> [1,2,3,4,5]
				this.getDesignersShots(ids); // 获取用户 shots

				// filter html and concat
				for (d of datas) {
					d.bio = filterHtml(d.bio);
					d.followers_count = addCommas(d.followers_count);
					obj['designers'].push(d);
				}
				
				obj['pageIndex'] = _page;
			}
			this.setData(obj)
		})
	},
	/*
		滚动到底部加载数据
	 */
	loadMore: function(){
		let page = ++this.data.pageIndex;
		console.log('loadMore:', page);
		this.getDesigners(page);
	},
	/*
		关注按钮事件
	 */
	followDesigner: function(e){
		let { id } = e.currentTarget.dataset;
		console.log('follow designer:', id);
	},
	onLoad: function(options) {
		this.getDesigners();
    wx.getSystemInfo({
        success: (res) => {
        	let shotWidth = (res.windowWidth - 40) * 0.475;
            this.setData({
            	windowWidth: res.windowWidth,
            	windowHeight: res.windowHeight,
              shotWidth: shotWidth,
              shotHeight: shotWidth * 0.75
            })
        }
    });
	}
})

下载地址:代码

作者 east
Java 3月 14,2021

Java开发最全学习资料(持续更新)

学习视频:

零基础小白真正轻松学Java|2020入门Java高薪

JAVA设计模式

Java零基础全栈就业班

java高级大互联网架构师进阶

Java分布式锁实战教程(基于Spring Boot)

Redis高并发高可用集群 整合SpringBoot百万级秒杀实战

WebSocket整合Spring、SockJS、Stomp、Rabbitmq分布式消息推送

SpringBoot2.0前后端分离开发之用户身份认证实战 (后端实现)

Spring Cloud Alibaba特训营

全新版本分布式架构教程 SpringCloud+Docker基础入门到高级实战

Spring特训营(手写篇)java高级开发 java架构师进阶课程

JVM深入浅出特训营

MySQL数据库深度讲解(设计+SQL语句)视频课程

MySQL从入门到入魔,Java高级,java进阶

深入Mybatis原理与实战

全新录制Elasticsearch7.X搜索引擎项目实战Java架构视频教程

企业级搜索引擎 ElasticSearch 7 实战

ES训练营/基于ElasticStack快速打造三位一体实时监控分析平台

700多分钟干货实战,Java多线程高并发高性能实战全集

分布式医疗云平台项目实战

Docker 网络详解

Nginx 从入门到百万并发实战

作者 east
人工智能 3月 14,2021

人工智能最全学习教程(持续更新)





学习视频:

零基础学Python

Python教程-零基础快速入门知识

手把手教你学Python(进阶篇)

Python入门到精通

Python高薪实战训练营

Python零基础数据分析与机器学习

Python编程零基础入门到精通体系课 数据分析机器学习Web开发应用

利用Python做验证码的识别

Python爬虫scrapy框架速通教程

机器学习入门到实战( 手推算法)

大数据时代的知识图谱(一线大厂经验)

唐宇迪2天自然语言处理训练营/NLP架构实战/神经网络/深度学习

逆战2020、学人工智能用代码观疫情

作者 east
大数据开发 3月 14,2021

大数据开发最全学习资料(持续更新)

Hadoop从0到精通详解教程,2021年最新全套

大数据开发-合适新手入门+深入

大数据开发就业教程

大数据全栈就业班 


大数据基石Hadoop由浅入深,从原理到源码全面征服

基于淘宝从架构到需求,由浅入深全面了解大数据的数据仓库

大数据金融离线数据仓库项目实战与运营分析

大数据Scala编程语言完整视频教程

大数据生态圈/Hadoop/Spark/Flink/数据仓库/实时分析/推荐系统

Flink大数据项目实战【大讲台】

大数据Spark实战训练营/3天掌握Spark京东电商实战案例

基于淘宝从理论到实战由浅入深全面了解最火的实时框架Flink

医药数据分析通识课:SAS编程与CDISC标准

作者 east
小程序代码 3月 14,2021

微信小程序最全开发资料(持续更新)

1:官方工具:https://mp.weixin.qq.com/debug/w … tml?t=1476434678461

2:简易教程:https://mp.weixin.qq.com/debug/wxadoc/dev/?t=1476434677599

3:设计指南:https://mp.weixin.qq.com/debug/wxadoc/design/index.html

4:设计资源下载:https://mp.weixin.qq.com/debug/wxadoc/design/#资源下载

电子书:

微信小程序开发入门与实践

微信小程序开发实战

微信小程序:开发入门与案例详解

零基础学:微信小程序开发

小程序实战视频课:微信小程序开发全案精讲

微信小程序开发实战

小程序从0到1:微信全栈工程师一本通

微信公众平台与小程序开发:从零搭建整套系统(第2版)

微信小程序开发详解

微信小程序开发实战

学习视频:

微信小程序、零基础入门、基础语法讲解(微信小程序教程)

6小时轻松掌握Web前端微信小程序/云开发0基础全套教程

微信小程序样式入门到精通(wxss,css)-微信小程序开发入门视频教

小程序开发从入门到精通-大神精选

小程序常用功能开发与实战

零基础玩转微信小程序

一天教你打造企业级微信小程序 bilibili项目实战

微信小程序商城 15天从零实战 在线视频教程 (第一季)

微信支付从入门到实战-PHP进阶实战

微信小程序快速入门2020版

微信小程序培训班(适合零基础和非iT计算机行业)(882节课)

微信小程序实战

微信小程序新版canvas开发

新版微信小程序教程零基础入门到项目实战教程前端js视频教程

微信小程序零基础快速入门项目实战/豆瓣电影

微信小程序案例开发之成语消消乐游戏开发视频课程

微信小程序主流商城实战项目

微信小程序实战入门(内含完整实例解析)

作者 east
社交 3月 14,2021

即时聊天微信小程序代码

仿照hiapp,首页是朋友圈新闻,第二栏是通讯录,可以进行聊天。采用flex布局,像微信那样聊天,自己发的聊天在右侧。

  <scroll-view scroll-y="true" class="timeline flex-rest-height">
    <block wx:for="{{messages}}">
      <view class="message flex-row {{item.from === 'sent' ? 'message-sent' : ''}}">
        <text wx:if="{{!item.image}}" class="message-text {{item.from === 'sent' ? 'message-sent-text' : 'message-received-text'}}">{{item.text}}</text>
        <image wx:else src="{{item.text}}" class="message-image"></image>
      </view>
    </block>
  </scroll-view>

  <view class="footer flex-row">
      <view class="input-container flex-rest-width">
        <input id="message" value="{{inputValue}}" placeholder="message..." class="message-input" bindchange="bindChange"/>
      </view>
      <view class="btn-area">
        <button bindtap="sendMessage" class="send-message-btn" type="primary" size="mini">Send</button>
      </view>
  </view>
</view>

下载地址:项目工程

作者 east

上一 1 … 59 60 61 … 93 下一个

关注公众号“大模型全栈程序员”回复“小程序”获取1000个小程序打包源码。回复”chatgpt”获取免注册可用chatgpt。回复“大数据”获取多本大数据电子书

标签

AIGC AI创作 bert chatgpt github GPT-3 gpt3 GTP-3 hive mysql O2O tensorflow UI控件 不含后台 交流 共享经济 出行 图像 地图定位 外卖 多媒体 娱乐 小程序 布局 带后台完整项目 开源项目 搜索 支付 效率 教育 日历 机器学习 深度学习 物流 用户系统 电商 画图 画布(canvas) 社交 签到 联网 读书 资讯 阅读 预订

官方QQ群

小程序开发群:74052405

大数据开发群: 952493060

近期文章

  • 如何在Chrome中设置启动时自动打开多个默认网页
  • spark内存溢出怎样区分是软件还是代码原因
  • MQTT完全解析和实践
  • 解决运行Selenium报错:self.driver = webdriver.Chrome(service=service) TypeError: __init__() got an unexpected keyword argument ‘service’
  • python 3.6使用mysql-connector-python报错:SyntaxError: future feature annotations is not defined
  • 详解Python当中的pip常用命令
  • AUTOSAR如何在多个供应商交付的配置中避免ARXML不兼容?
  • C++thread pool(线程池)设计应关注哪些扩展性问题?
  • 各类MCAL(Microcontroller Abstraction Layer)如何与AUTOSAR工具链解耦?
  • 如何设计AUTOSAR中的“域控制器”以支持未来扩展?

文章归档

  • 2025年8月
  • 2025年7月
  • 2025年6月
  • 2025年5月
  • 2025年4月
  • 2025年3月
  • 2025年2月
  • 2025年1月
  • 2024年12月
  • 2024年11月
  • 2024年10月
  • 2024年9月
  • 2024年8月
  • 2024年7月
  • 2024年6月
  • 2024年5月
  • 2024年4月
  • 2024年3月
  • 2023年11月
  • 2023年10月
  • 2023年9月
  • 2023年8月
  • 2023年7月
  • 2023年6月
  • 2023年5月
  • 2023年4月
  • 2023年3月
  • 2023年1月
  • 2022年11月
  • 2022年10月
  • 2022年9月
  • 2022年8月
  • 2022年7月
  • 2022年6月
  • 2022年5月
  • 2022年4月
  • 2022年3月
  • 2022年2月
  • 2022年1月
  • 2021年12月
  • 2021年11月
  • 2021年9月
  • 2021年8月
  • 2021年7月
  • 2021年6月
  • 2021年5月
  • 2021年4月
  • 2021年3月
  • 2021年2月
  • 2021年1月
  • 2020年12月
  • 2020年11月
  • 2020年10月
  • 2020年9月
  • 2020年8月
  • 2020年7月
  • 2020年6月
  • 2020年5月
  • 2020年4月
  • 2020年3月
  • 2020年2月
  • 2020年1月
  • 2019年7月
  • 2019年6月
  • 2019年5月
  • 2019年4月
  • 2019年3月
  • 2019年2月
  • 2019年1月
  • 2018年12月
  • 2018年7月
  • 2018年6月

分类目录

  • Android (73)
  • bug清单 (79)
  • C++ (34)
  • Fuchsia (15)
  • php (4)
  • python (45)
  • sklearn (1)
  • 云计算 (20)
  • 人工智能 (61)
    • chatgpt (21)
      • 提示词 (6)
    • Keras (1)
    • Tensorflow (3)
    • 大模型 (1)
    • 智能体 (4)
    • 深度学习 (14)
  • 储能 (44)
  • 前端 (5)
  • 大数据开发 (493)
    • CDH (6)
    • datax (4)
    • doris (31)
    • Elasticsearch (15)
    • Flink (79)
    • flume (7)
    • Hadoop (19)
    • Hbase (23)
    • Hive (41)
    • Impala (2)
    • Java (71)
    • Kafka (10)
    • neo4j (5)
    • shardingsphere (6)
    • solr (5)
    • Spark (100)
    • spring (11)
    • 数据仓库 (9)
    • 数据挖掘 (7)
    • 海豚调度器 (10)
    • 运维 (35)
      • Docker (3)
  • 小游戏代码 (1)
  • 小程序代码 (139)
    • O2O (16)
    • UI控件 (5)
    • 互联网类 (23)
    • 企业类 (6)
    • 地图定位 (9)
    • 多媒体 (6)
    • 工具类 (25)
    • 电商类 (22)
    • 社交 (7)
    • 行业软件 (7)
    • 资讯读书 (11)
  • 嵌入式 (71)
    • autosar (63)
    • RTOS (1)
    • 总线 (1)
  • 开发博客 (16)
    • Harmony (9)
  • 技术架构 (6)
  • 数据库 (32)
    • mongodb (1)
    • mysql (13)
    • pgsql (2)
    • redis (1)
    • tdengine (4)
  • 未分类 (7)
  • 程序员网赚 (20)
    • 广告联盟 (3)
    • 私域流量 (5)
    • 自媒体 (5)
  • 量化投资 (4)
  • 面试 (14)

功能

  • 登录
  • 文章RSS
  • 评论RSS
  • WordPress.org

All Rights Reserved by Gitweixin.本站收集网友上传代码, 如有侵犯版权,请发邮件联系yiyuyos@gmail.com删除.